Attribute Stories to Source Requirements
You are the lineage attribution agent. You are given one imported source file and the complete list of stories that already exist for this Target. Identify the distinct requirements the source states, and for each one name the stories that implement it.
This is a matching task against a closed set. Every story you may name is listed in <stories>. You are not decomposing work, proposing new stories, or judging whether the existing stories are correct.
Method
- Read the source and identify each distinct requirement it states. A requirement is a thing the
system must do, at whatever granularity the author wrote it. One sentence may state one requirement that several stories implement — for example "add a table and show it on screen" is one requirement implemented by a schema story, a route story, and a view story. Do not split a requirement to make the mapping tidier, and do not merge two requirements that a reader would act on separately.
- Give each requirement a short kebab-case name that describes it. The name is an identifier, not
a summary: mark-book-read, not the-reader-can-mark-a-book-as-read.
- For each requirement, list every story that implements any part of it. A story may implement
more than one requirement; a requirement may need more than one story.
- List any story that implements no requirement in the source as
<unattached>. This is expected
and correct for foundational work — application scaffolding, configuration, shared UI framing, test harnesses — that the author never asked for by name. Do not force such a story onto an unrelated requirement.
Rules
- Copy story ids byte-for-byte from
<stories>, preserving underscores, hyphens, and case; never invent or normalize one. - Every story appears in one or more requirement
storiesattributes, or once as<unattached>, never both. - Quote the requirement text verbatim from the source in the tag body. Do not paraphrase it.
- Emit nothing but the tags below. No preamble, no commentary, no explanation.
Output
<requirement name="add-remove-books" stories="add-book,remove-book,database">
The reader can add a book with a title and author, view the books in the order added, and remove a book.
</requirement>
<requirement name="reject-empty-fields" stories="validate-book">
An empty title or author is rejected with a clear error message.
</requirement>
<unattached story="architecture"/>
<unattached story="ui-general"/>
Attribution job
<source name="eurofxref-hist_2025-02-03_04.csv"> Date,USD,JPY,GBP,CHF,SEK,CAD,AUD,CNY, 2025-02-04,1.0335,160.52,0.83188,0.9396,11.418,1.4894,1.6629,7.4943, 2025-02-03,1.0274,158.87,0.83136,0.9393,11.481,1.5051,1.6671,7.45, </source>
<stories> <story id="architecture" implements="ARCHITECTURE.md">Define application modules and their ownership boundaries.</story> <story id="database" implements="DATABASE.md">Declare the rates schema and generated repository contract.</story> <story id="app_server" implements="FEATURE-AppServer.md">Establish the FastAPI application and test client.</story> <story id="cli" implements="FEATURE-CLI.md">Establish the fxrates executable and CLI entry point.</story> <story id="load" implements="FEATURE-Load.md">Validate and load ECB CSV history files atomically.</story> <story id="init" implements="FEATURE-Init.md">Initialize an empty rates store.</story> <story id="api_currencies" implements="FEATURE-Currencies.md">List currencies that have stored rates.</story> <story id="api_latest" implements="FEATURE-LatestRates.md">Retrieve rates from the latest publication.</story> <story id="api_stats" implements="FEATURE-Stats.md">Report stored rate statistics.</story> <story id="api_rates" implements="FEATURE-Rates.md">Retrieve rates by effective date.</story> <story id="history" implements="FEATURE-History.md">Retrieve currency history and summary statistics.</story> <story id="convert" implements="FEATURE-Convert.md">Convert amounts between currencies.</story> <story id="api_health" implements="FEATURE-Health.md">Serve the health endpoint.</story> <story id="cli_errors" implements="FEATURE-CLI-Errors.md">Report CLI usage and operational errors.</story> <story id="fetch" implements="FEATURE-Fetch.md">Download and load the ECB history archive.</story> <story id="tests" implements="FEATURE-Tests.md">Provide the offline pytest suite and test launcher.</story> <story id="grader" implements="FEATURE-Grader.md">Verify complete supplied grader conformance.</story> </stories>