
Research To Json
- 2 installs
- 1 repo stars
- Updated March 2, 2026
- ansanabria/tinto-politico-app
research-to-json is a skill that transforms candidate research markdown into deterministic per-candidate JSON files mapped to a Payload CMS Candidates collection.
About
research-to-json is a skill that transforms candidate research markdown files into deterministic per-candidate JSON files for seeding a Payload CMS. A developer uses it to convert, structure or normalize candidate research into one JSON file per candidate that maps directly to the Candidates collection fields. It follows explicit mapping rules, preserves Spanish text faithfully, enforces enum quality checks, and keeps output deterministic without inventing content.
- Transforms candidate research markdown into deterministic per-candidate JSON
- Maps headings to an explicit Candidates CMS collection contract
- Enforces enum quality checks for tiers, statuses and social platforms
Research To Json by the numbers
- 2 all-time installs (skills.sh)
- Ranked #1,839 of 2,715 Automation & Workflows skills by installs in the Skillselion catalog
- Data as of Jul 28, 2026 (Skillselion catalog sync)
research-to-json capabilities & compatibility
- Capabilities
- data transformation · markdown parsing · cms seeding
- Use cases
- data analysis · database
What research-to-json says it does
Transform candidate research markdown files from research/ into deterministic per-candidate JSON files in data/.
Keep output deterministic so future runs over the same markdown produce the same JSON shape.
npx skills add https://github.com/ansanabria/tinto-politico-app --skill research-to-jsonAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 2 |
|---|---|
| repo stars | ★ 1 |
| Last updated | March 2, 2026 |
| Repository | ansanabria/tinto-politico-app ↗ |
What it does
Convert candidate research markdown into deterministic per-candidate JSON that maps to a Payload CMS Candidates collection.
Who is it for?
Normalizing candidate research markdown into structured, deterministic seed JSON for a CMS.
Skip if: Generating a single multi-candidate JSON document or inventing content not in the research.
When should I use this skill?
A user asks to convert, structure, normalize or prepare candidate research for seeding or Payload ingestion.
What you get
One deterministic JSON file per candidate mapped to the Candidates collection, with enum-validated fields and faithful Spanish text.
- per-candidate JSON files
- Candidates collection seed data
By the numbers
- 8 mapping rules
- 6 pre-write quality checks
- one JSON file per candidate
Files
Research Markdown -> Candidate JSON
Use this skill to convert research/*.md files into structured candidate JSON files for seeding.
Goal
Produce one JSON file per candidate in data/:
research/ivan-cepeda.md->data/ivan-cepeda.jsonresearch/abelardo-de-la-espriella.md->data/abelardo-de-la-espriella.json
Do not generate one big multi-candidate JSON document.
Output contract
Write a JSON object that maps directly to the Candidates collection fields:
{
"name": "string",
"slug": "string",
"party": "string",
"currentOffice": "string",
"lastUpdated": "YYYY-MM-DD",
"socialLinks": [
{ "platform": "x|instagram|facebook|youtube", "url": "https://..." }
],
"biography": "string",
"publicTrajectoryItems": [
{
"role": "string",
"organization": "string",
"startYear": "string",
"endYear": "string",
"location": "string",
"description": "string"
}
],
"privateTrajectoryItems": [
{
"role": "string",
"organization": "string",
"startYear": "string",
"endYear": "string",
"location": "string",
"description": "string"
}
],
"proposals": "string",
"proposalItems": [
{
"title": "string",
"description": "string",
"topic": "string",
"sourceTitle": "string",
"sourceUrl": "https://...",
"sourceTier": "oficial|prensa|ong|redes"
}
],
"controversies": "string",
"controversyItems": [
{
"title": "string",
"description": "string",
"status": "suspicion|under_investigation|indicted|cleared|convicted",
"year": "string",
"sourceTitle": "string",
"sourceUrl": "https://...",
"sourceTier": "oficial|prensa|ong|redes"
}
],
"alliances": "string",
"allianceParties": [{ "name": "string" }],
"endorsers": [{ "name": "string" }],
"record": "string",
"funding": "string",
"sources": [
{
"section": "biography|proposals|controversies|alliances|record|funding",
"title": "string",
"publishedAt": "YYYY-MM-DD",
"url": "https://...",
"tier": "oficial|prensa|ong|redes"
}
],
"summaryTrajectory": "string",
"summaryProposals": "string",
"summaryControversies": "string",
"summaryAlliances": "string",
"summaryRecord": "string",
"summaryFunding": "string"
}Mapping rules
1. Read the research markdown headings and map by explicit CMS field names in backticks. 2. Parse code-block list items (1., 2., etc.) into arrays preserving order. 3. Keep wording faithful to the research file; do not invent or embellish. 4. Normalize keys to exact field names from the contract above. 5. For optional arrays with no entries, use []. 6. Keep dates in YYYY-MM-DD where present. 7. Preserve Spanish text exactly (except minimal cleanup for broken whitespace). 8. Exclude operational notes (e.g., "subir manualmente") from JSON values.
Quality checks before writing
slugmust match output filename.socialLinks[].platformmust be one of:x,instagram,facebook,youtube.sourceTierandsources[].tiermust be one of:oficial,prensa,ong,redes.controversyItems[].statusmust be one of:
suspicion, under_investigation, indicted, cleared, convicted.
sources[].sectionmust be one of:
biography, proposals, controversies, alliances, record, funding.
Behavior expectations
- If a field is truly missing in research markdown, leave it as an empty string or empty array (whichever matches type) and mention it in your final note.
- Never insert opinions, rankings, or sentiment language.
- Keep output deterministic so future runs over the same markdown produce the same JSON shape.
Related skills
FAQ
One JSON file or many?
The docs require one JSON file per candidate, not one big multi-candidate document.
Can it embellish research?
No, the docs say to keep wording faithful, not invent or embellish, and never insert opinions or sentiment.