Skip to content

feat(copy): Spanish bot copy for hackathon analysis (spanish-copy 1/3) - #39

Merged
TOMOKI977 merged 5 commits into
mainfrom
feat/spanish-copy-hackathon
Sep 29, 2026
Merged

TOMOKI977 merged 5 commits into
mainfrom
feat/spanish-copy-hackathon

Conversation

@TOMOKI977

Copy link
Copy Markdown
Contributor

Summary

This is PR 1 of 3 for change spanish-copy. From now on, all bot-authored Telegram text is in neutral Spanish (tuteo). This PR covers the hackathon analysis area. It changes copy only; behavior is unchanged.

  • src/domain/copy.ts (new): the domain copy catalog. It holds the analysis labels ("Nombre:", "Premios:", "Fecha límite de entrega:", …), "…y N más", the job outcome replies, the link notes, and the "Analizando …" acknowledgement. The six fetch-failure kinds map to Spanish phrases through an exhaustive Record<PageFetchFailureKind, string>, so a new kind fails the typecheck.
  • src/adapters/telegram/copy.ts (new): the adapter catalog, with commonCopy and hackathonCopy in this PR. It imports the domain catalog and never the reverse.
  • Updated to the catalogs: format.ts, text-limit.ts, run-hackathon-job.ts, link-analysis-to-topic.ts, request-hackathon-analysis.ts and hackathon-commands.ts.
  • test/copy/catalog-language.test.ts (new): a guard that fails if a catalog contains common English words.
  • Docs: openspec/changes/spanish-copy/ adds the proposal, the delta specs (a new bot-copy capability and changes to hackathon-analysis), the design with the full copy table, the tasks and apply-progress.

Unchanged

  • Analysis field values taken from web pages stay in the page's language, and snippets stay verbatim.
  • The LLM prompt, code, identifiers, logs and log reason codes stay in English.
  • The fetch, LLM and validation logic is untouched, so npm run harness is not needed.

Known interim

  • /repos still prints the English "...and N more" until PR 2, which covers profile, team, membership and repo commands plus the team picker.
  • GitHub alerts are translated in PR 3.

Review

A bounded review ran at medium risk with the reliability lens on all 24 changed paths and found nothing. It confirmed that:

  • the copy matches the design and spec exactly, with consistent tuteo;
  • the label order and the 4096-character cap are preserved;
  • the domain does not import the adapter;
  • the fetch-kind map is exhaustive.

Tests

  • Strict TDD: 57 tests were RED before the catalogs existed.
  • The full suite passes (828 tests), and the typecheck is clean.

🤖 Generated with Claude Code

@TOMOKI977 TOMOKI977 added the size:exception PR over the 400-line review budget, accepted explicitly label Sep 29, 2026
@TOMOKI977
TOMOKI977 merged commit c4e7248 into main Sep 29, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:exception PR over the 400-line review budget, accepted explicitly

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant