Continguts i IA
Editorial Automation for Pànxing.net
An application that transforms documents, posters, programs and other editorial materials into drafts ready to review and send to WordPress, while keeping control over sources and important data.
Pànxing.net is a website that gathers the information published in the printed magazines of the Pànxing Cerdanya, Pànxing Maresme and Pànxing Berguedà titles.
To produce these magazines, the team receives very different materials: Word documents, PDFs, texts, posters, activity programs and photographs.
These materials must ultimately become content for the web and, subsequently, WordPress entries according to the corresponding category and municipality.
The project was created to help with this process: read the materials, prepare a first editorial proposal and let the editor focus on confirming data, resolving doubts and approving the result.
Project Evolution
The project began with a general idea: to create a tool that would help transform editorial materials into content for Pànxing.net.
The first version served to validate the concept. It was tested whether it was possible to extract information, classify the materials and generate texts with AI.
As real cases were tested, new problems appeared: incomplete documents, hard-to-read posters, incorrect classifications, dates with different formats and content that needed different editorial handling.
The following versions gradually incorporated the full flow: material import, classification, content generation and WordPress export.
One of the intermediate versions, which was internally considered a V2 but actually corresponded to a third stage, added much of the current foundation of the project.
From this base, the following were incorporated:
- source review;
- detected facts and evidence;
- editorial profiles;
- SEO rules;
- structures by category;
- image preparation;
- manual correction;
- validation before export;
- SMB synchronization;
- persistent batch processing;
- selective retries;
- idempotent submission to WordPress.
The current version is the result of this process. It is no longer just a prototype to check whether the idea worked, but a functional MVP that solves the main flow and allows it to continue scaling.
How It Works
1. SMB Synchronization
The editor manually starts the synchronization with the shared SMB folder.
The application goes through the compatible files, copies them to its own workspace and calculates a SHA-256 fingerprint to avoid duplicates.
The original files are not moved, renamed or their content is not altered.
Synchronization works as an independent job. The interface shows the progress of the copy and allows seeing which items have been imported, which already existed and which have failed.
2. Source Analysis
When the copy has finished, a second analysis phase begins.
The system extracts text from DOCX, PDF, TXT and Markdown files. In the case of images, it can use local OCR, visual transcription with AI or both options.
The results are kept separately. This makes it possible to check what OCR has read, what the visual model has interpreted and what information comes directly from the document.
If some content fails, the problem is associated only with that element. The rest of the batch can continue and the failed element can be retried later.
3. Classification
The initial classification uses the folder and the file names. Then, the application can analyze the content to confirm or propose another category and municipality.
The available options come from a configured catalog. If the initial and analyzed classifications do not match, the system shows the difference and asks the editor to confirm it.
The category determines the editorial treatment and also the type of content that will be sent to WordPress.
4. Source Review
Before generating the article, the editor can open the content card.
In this card they can check the original files, the extracted text, the visual transcription, the images and the detected facts.
They can also add confirmed data or editorial instructions. For example, they can confirm a complete date that is not read well on the poster, or indicate that an interview should be preserved with its question-and-answer format.
This step makes it possible to settle doubts before writing and prevents the AI from trying to automatically fill in the missing parts.
5. Content Generation
Once the sources have been reviewed, the editorial draft is generated.
The configuration allows assigning different providers and models depending on the task: classification, visual transcription, generation, correction, validation or image generation.
The main editorial profiles are:
- Strict agenda: preserves the program and only uses confirmed data.
- Literal interview: keeps the questions, answers and original order.
- Loyal client: corrects the text with minimal intervention.
- Controlled editorial: improves the structure without adding new information.
AI helps to order and write the content, but it cannot fill in missing data.
6. Agenda Handling
Agendas have been one of the most difficult parts of the project.
A program can have several activities, different days, times, prices and locations. In addition, the information can appear in different formats or be spread across several pages and images.
Dates are not decided by the AI. The application normalizes them with code and differentiates between single-day events, day lists and periods with start and end dates.
If a date is incomplete or cannot be verified, the agenda is blocked until the editor confirms it.
This prevents the system from deducing the year, inventing an end date or turning partial information into an incorrect event.
7. Images
Imported images are kept together with the content they belong to.
The application can create optimized versions for the web without altering the original. The editor can select the featured image, add alternative text and decide which images appear within the article.
When no image is available, a cover can be generated with MiniMax. This image is identified as AI-generated and is not considered an informational source.
8. Validation
Before exporting, the content goes through automatic validation.
The validation checks dates, times, prices, municipalities, categories, metadata and main facts. It also detects missing critical information, contradictions and data that is not supported by the sources.
The results are divided into:
- Correct: the content can be exported.
- Warning: there is a possible improvement, but it does not block the process.
- Error: the information must be corrected or confirmed before continuing.
The editor can modify the Markdown from the same card and validate it again.
9. Submission to WordPress
When the content is valid, a submission job to WordPress is created.
The system prepares the payload according to the category, assigns the corresponding CPT, links the municipality and adds the necessary taxonomies and metadata.
It also sends only the selected images, keeping the originals untouched, and uses a stable identifier to avoid duplicates in case of retry.
WordPress always receives a draft. Final publication continues to depend on editorial review.
Difficulties
Starting with an Idea and Turning It into a Functional Product
The project did not start with a closed specification. At the beginning only the general purpose was clear: to help prepare the materials for Pànxing.net.
The process consisted of creating prototypes, testing them with real materials, checking what worked and detecting which parts did not add enough value.
Some ideas seemed good initially but complicated the flow or were not reliable enough. This forced simplifications, separating phases, prioritizing important functions and turning the initial prototype into a functional MVP.
Generating Content Without Creating False Information
AI generation was useful, but it was also the riskiest part.
The system had to be able to transform a short text or a poster into a readable article without adding data that did not appear in the source.
To achieve this, prompts, editorial profiles, detected facts, editor instructions and independent validations were combined.
Generation had to serve to write better, not to fill gaps with invented information.
Creating Reliable Agendas
Agendas concentrated a large part of the complexity of the project.
It was not enough to extract the text from a poster. It was necessary to preserve all activities, correctly interpret the dates, differentiate ranges, detect incomplete information and prepare the data WordPress needs.
The final solution separates writing from date management. AI can help write the content, but dates are calculated and validated deterministically.
Reading Posters and Visual Documents
Posters can have columns, decorative fonts, complex backgrounds or highly condensed information.
Local OCR is useful, but it does not always interpret the visual distribution well. AI transcription can provide a better reading, but it also has to be reviewed.
For this reason, the application keeps the results from both paths and shows them to the editor before generating the article.
Processing Batches with Partial Errors
A synchronization can contain many files and not all fail for the same reason.
The solution was to create persistent jobs with per-item progress, selective retries and recovery after a restart.
In this way, a connection, OCR or WordPress error does not force starting the whole process over again. It is only necessary to retry the items that have not completed their phase.
Result
The project has turned a manual editorial process into a more orderly and controlled workflow.
Materials arrive from the shared folder. The application imports them without altering the originals, extracts the information, proposes a classification and prepares an editorial draft.
Before sending it to WordPress, the editor can review the sources, confirm the important data and correct the text. Validation checks that no necessary data is missing and that the main information matches the original documents.
In this way, the team reduces the time spent on repetitive tasks, but keeps control over the final content.
The system also allows working with batches, retrying only the elements that fail and recovering interrupted processes. When the content is valid, the submission to WordPress is prepared as a draft, with the corresponding category, municipality, images and metadata.
The result is a functional and stable foundation that already solves the main flow and can be extended with additional categories, models and integrations.
Lessons Learned
The development of the project has consisted of finding the balance between automation and editorial control.
Not all parts of the process should be automated in the same way. Reading, initial classification, writing and image preparation can be streamlined. On the other hand, dates, prices, municipalities and other important data need stricter checking.
For this reason, the application separates the different phases of the process. First it imports the materials. Then it analyzes them. Next it generates the content and, before sending it to WordPress, validates it.
Agendas have been the best example of this need. AI can help order and write a program, but dates are treated as structured data and calculated with their own rules.
The editorial configuration has also been separated from the code. The models, prompts, structures, structures, SEO rules and the templates can be modified without having to change the application.
The result is a tool that automates an important part of the work, but that keeps the sources, exceptions and decisions that still belong to the editor visible.
The result is a tool that automates a significant part of the editorial work that Pànxing used to do manually: collecting, validating, and drafting content. The team keeps the final say, but the daily workload is much lighter.