3 ms·
I haven’t looked under the hood here but to make simple text replacement via command line is an LLM even required? A human driven command line tool to do basic
by rubyfan 3mo ago
I haven’t looked under the hood here but to make simple text replacement via command line is an LLM even required? A human driven command line tool to do basic substitution on batches of files reliably would be amazing.
- BorisMelnik 3mo agothere is a python library for docx handling. my thinking was the use case for this was for larger scale automations / document processing.
- asdff 3mo agosed, awk. docx is just zipped xml.
- phil-martin 3mo agoIt is just zipped xml, but to do a search and replace while retaining document structure is very very complicated, and I’m struggling to think of how to combine sed and awk to achieve it.
- cyanydeez 3mo agoyou've never dealt with ooxml.
- rubyfan 3mo agoSadly I have spent lots of time with ooxml and pdf and my experience suggests there really aren’t reliable means for dealing with seemingly simple changes.
- kirillklimuk 3mo agoNot really - if you wanna do a text replacement you can extract it yourself and do some work (or just use this CLI). The library is designed for longer workloads.