Atris

Write a decision memo from option notes.
Done by an agent. Checked twice.

A memo with every option side by side, its cost, risks and unknowns, built only from what the notes say.

Have Atris do this for you›

1

Real files in

  • costs.csv
    The cost sheet for the decision: 30 lines, with a cost entered twice, two quotes that conflict, a blank amount and a line for an idea nobody wrote up. 31 lines, 2 KB.
  • move.md
    A manager's note on the option to move, with a three year total that does not equal the cost sheet. 23 lines, 1 KB.
  • outsource.md
    A manager's note on the option to outsource, with risks and open questions. 24 lines, 1 KB.
  • renew.md
    A manager's note on the option to renew the lease, with risks and open questions. 26 lines, 1 KB.
  • split.md
    A manager's note on the option to split the work, with risks and open questions. 22 lines, 1 KB.
  • question.md
    The chief executive's one page statement of the decision, the deadline and what matters. 24 lines, 1 KB.

Sample data written by Atris. Not a real company.

2

Three steps

  1. 1.Read the question and the options
  2. 2.Work out the costs and collect the evidence
  3. 3.Write the memo

Claude Sonnet 5.5, 1 min 6 s. No web. It never saw the check.

3

Checked twice

  • ✓Passed: 4 of 4 options with a note are in options.csv and 0 options were added
  • ✓Passed: 4 of 4 options have the one time, yearly and three year cost worked out again from the cost sheet
  • ✓Passed: 8 of 8 risk and unknown counts in options.csv equal the points listed in the notes and the rows of evidence.csv
  • ✓Passed: 28 of 28 risks and unknowns written in the notes are quoted in evidence.csv
  • ✓Passed: 28 of 28 quotes in evidence.csv are word for word in the note they name
  • ✓Passed: 22 of 22 figures of 1,000 or more in memo.md trace to the cost sheet, the notes or the worked out totals
  • ✓Passed: 8 of 8 figures under 1,000 in memo.md are printed in the question, a note or the cost sheet
  • ✓Passed: 5 of 5 problems in the cost sheet are named in memo.md with their line ids or both figures
  • ✓Passed: memo.md is 781 words, inside the 800 word limit

Second review by Claude Opus 5.5: pass.

Then we broke a copy of the output 9 ways on purpose. The check caught 9.

What it wrote. Lines 6 to 14 of memo.md, copied from the file.
## Options at a glance
| Option | One time cost | Yearly cost | Three year cost | Cost complete |
|---|---|---|---|---|
| renew | 36,000 | 875,000 | 2,661,000 | yes |
| move | 212,700 | 930,000 | 3,002,700 | no |
| outsource | 190,500 | 732,400 | 2,387,700 | yes |
| split | 168,500 | 836,400 | 2,677,700 | yes |

Move is 615,000 above outsource, and its figure excludes lost sales during the move.

How this was run

An AI agent on Claude Sonnet 5.5 was given a folder with the files below and a three-step flow, and nothing else. It had no web access and never saw the check. The check was written before the run and made stricter after it. It works the answer out again from the input files. Then Claude Opus 5.5 reviewed the result against the inputs. The input files are sample data written by Atris, with the problems a real week has planted in them.

Run 2 of 2 on 1 December 2026. The agent took 1 min 6 s. Run 1 passed both checks and the job was run again later. Each run starts clean. Between runs the written flow was made clearer, or a check was corrected or made stricter. Nobody edits the output.

What the second review verified

  • Recomputed every cost from costs.csv. Duplicate L-06 counted once, the higher of the two conflicting quotes (L-11, 52,500) used, blank L-14 left out and buy line L-30 dropped. Totals: renew 36,000 + 3×875,000 = 2,661,000; move 212,700 + 3×930,000 = 3,002,700; outsource 190,500 + 3×732,400 = 2,387,700; split 168,500 + 3×836,400 = 2,677,700. All match options.csv and the memo table.
  • evidence.csv has all 28 points (17 risks, 11 unknowns) copied word for word from the four notes, e.g. 'Getting stock back out is slow and costly if it does not work.' The risk and unknown counts in options.csv (4/3, 5/3, 4/3, 4/2) are correct.
  • The cost sheet section names L-01/L-06, L-10/L-11 (and says L-11 was counted), L-14 and L-30. It reports move.md's 'about 2,960,000' against the worked-out 3,002,700. The 615,000 gap equals 3,002,700 − 2,387,700.
  • The memo is 781 words, under the 800 limit. It makes no recommendation, as question.md asked. Buying a building is listed only as an idea, not an option. 'What to find out' holds only the notes' not-known points plus blank L-14. Every figure of 1,000 or more is in options.csv or an input file, or is the allowed gap.

What this run does not show

  • The check confirms every risk and unknown in the notes is quoted word for word. The option summaries in the memo's own words are read only by the second review.
  • Figures in the memo are traced to the files. A figure swapped for another one printed in the files, such as a date, gets through.
  • The option notes were written for this run with clear headings for risks and unknowns. Real notes rarely sort themselves that well.

Would the check catch a wrong answer?

A check that cannot fail proves nothing. After the run we took a copy of the output, broke it one small way at a time and ran the check again. It caught 9 of 9. The check was made stricter after the first try at this, and the same untouched output was graded again.

Open every file

flow.md · the three steps the agent followed
# Write a decision memo from option notes

function: leadership
for: the executive who has to choose between options other people wrote up
goal: The decision maker sees every option side by side with its cost, its risks and what is still unknown, and nothing in the memo was made up.

## 1. Read the question and the options
Read input/question.md, every note in input/options/ and input/costs.csv. An option is something that
has its own note. Its name is the note's file name without ".md", which is also its name in the option
column of costs.csv. An idea that is only mentioned inside a note, or that has cost lines but no note,
is not an option. Never add an option of your own.

## 2. Work out the costs and collect the evidence
Clean the cost sheet first:
- Two lines with the same option, item, type and amount are one cost entered twice. Count it once.
- Two lines with the same option, item and type but different amounts are two quotes that conflict.
  Count the higher one.
- A line with a blank amount is an unknown cost. Leave it out of the sums and mark the option's cost as
  not complete.
- Leave out lines for anything that is not an option.
Write output/options.csv with columns option,one_time_cost,annual_cost,three_year_cost,cost_complete,risks,unknowns.
One row for each option. three_year_cost is one_time_cost plus three times annual_cost. Costs are plain
numbers with no commas. cost_complete is yes or no. risks and unknowns are the counts from the next file.
Write output/evidence.csv with columns option,kind,quote,source_file. One row for every point listed
under a note's risks heading (kind `risk`) and every point under its not known heading (kind
`unknown`). quote is the point copied word for word from the note. source_file is the note's path,
such as input/options/renew.md. Do not add risks or unknowns that no note states.

## 3. Write the memo
Write output/memo.md, at most 800 words, with these sections in this order:
- "Decision needed": what is being decided, by whom and by when, from question.md.
- "Options at a glance": a table with one row for each option: one time cost, yearly cost, three year
  cost and whether the cost is complete.
- One short section for each option: what it is, its main risks and what is not known, in your own
  words but with nothing the note does not say.
- "Problems in the cost sheet": one line for each of these that you find, naming every line_id
  involved: a cost entered twice, two quotes that conflict (say which you counted), a blank amount, a
  line for something that is not an option, and a note that states a three year total different from
  the one you worked out (give both figures).
- "Ideas raised but not worked up": anything mentioned that has no note.
- "What to find out before choosing": only the points the notes list under their not known headings
  and the blank amounts in the cost sheet. Do not turn a risk into a question and do not add
  questions of your own.
Rules for figures: write them in full, such as 2,387,700. Every figure of 1,000 or more must be in
options.csv or printed in an input file. The only figure you may work out beyond options.csv is the
gap between two options' three year costs. Before you finish, list every figure of 1,000 or more in
memo.md and confirm each one.
Do not recommend an option unless question.md asks for a recommendation.

## Done looks like
- options.csv has one row for each note and no other option.
- Every risk and unknown in the notes is in evidence.csv, word for word.
- Every problem in the cost sheet is named with its line ids.
input/costs.csv · 31 lines, 2 KB
line_id,option,item,type,amount,source
L-01,renew,Rent at the new rate,annual,312000,Landlord letter of November 3
L-02,renew,Warehouse staff (9 people),annual,468000,Payroll
L-03,renew,Utilities and insurance,annual,54000,2026 actuals
L-04,renew,Racking repairs the landlord requires,one_time,36000,Contractor quote
L-05,renew,Overflow storage in peak season,annual,41000,2026 actuals
L-06,renew,Rent at the new rate,annual,312000,Landlord letter of November 3
L-07,move,Rent for the Kettleby Road unit,annual,396000,Agent listing
L-08,move,Warehouse staff (9 people),annual,468000,Payroll
L-09,move,Utilities and insurance,annual,66000,Agent estimate
L-10,move,Moving stock and racking,one_time,38000,Quote from Brisco Removals
L-11,move,Moving stock and racking,one_time,52500,Quote from Halden Haulage
L-12,move,New racking and fit out,one_time,145000,Contractor quote
L-13,move,Two weeks of double rent during the move,one_time,15200,Finance estimate
L-14,move,Lost sales during the move,one_time,,Not estimated
L-15,outsource,"Fulfilment fee, 96000 orders a year at 5.40",annual,518400,Provider proposal
L-16,outsource,Storage fee,annual,84000,Provider proposal
L-17,outsource,Returns handling,annual,62000,Provider proposal
L-18,outsource,Account manager on our side (1 person),annual,68000,Payroll
L-19,outsource,Setup and system connection,one_time,45000,Provider proposal
L-20,outsource,Redundancy pay for 8 warehouse staff,one_time,118000,Finance estimate
L-21,outsource,Moving stock to the provider,one_time,27500,Provider proposal
L-22,split,"Fulfilment fee, 96000 orders a year at 5.40",annual,518400,Provider proposal
L-23,split,Storage fee,annual,84000,Provider proposal
L-24,split,Rent for a small unit for returns and repairs,annual,78000,Agent listing
L-25,split,Returns and repairs staff (3 people),annual,156000,Payroll
L-26,split,Setup and system connection,one_time,45000,Provider proposal
L-27,split,Redundancy pay for 5 warehouse staff,one_time,74000,Finance estimate
L-28,split,Fit out of the small unit,one_time,22000,Contractor quote
L-29,split,Moving stock to the provider,one_time,27500,Provider proposal
L-30,buy,Deposit on a building,one_time,400000,Rough guess from the offsite
input/options/move.md · 23 lines, 1 KB
# Option: move to the Kettleby Road unit

Written by Rosalind Ferreira, head of operations, November 21, 2026.

## What it is
Take a new lease on a unit on Kettleby Road, 6 miles away. It has 60 percent more floor space and
four loading doors instead of two. The agent lists it at 396,000 a year. We would move in February
and March 2027, before peak season.

## Why I like it
It is the only option that gives us room for three years of growth with our own people. By my sums the
move costs about 2,960,000 over three years.

## Risks
- A move in February and March leaves no slack before peak season starts in April.
- We would run two buildings for at least two weeks and ship from both.
- Three of the 9 warehouse staff have told me the longer drive would be a problem for them.
- The unit has been empty for a year and the loading doors have not been tested.

## Not known yet
- What the move would cost us in lost or late orders. Nobody has estimated it.
- Which of the two removal quotes is realistic. They differ by a wide margin.
- Whether the agent will hold the unit until our December 14 meeting.
input/options/outsource.md · 24 lines, 1 KB
# Option: hand shipping to a fulfilment provider

Written by Anselm Okoro, finance lead, November 19, 2026.

## What it is
Close our own warehouse and pay a fulfilment provider to store, pick, pack and ship. I asked one
provider, Northfold Fulfilment, for a proposal. They charge 5.40 an order plus storage and returns
fees. We would keep one person to manage the account.

## Why I like it
The cost moves with order volume instead of being fixed. On the cost sheet it comes to 2,387,700 over
three years.

## Risks
- We would make 8 of the 9 warehouse staff redundant.
- The provider ships for about 40 other brands and we would not be their largest customer.
- Their proposal promises to ship within two working days, which is slower than what we do today.
- The fee per order is fixed for 12 months only.
- Getting stock back out is slow and costly if it does not work.

## Not known yet
- What the fee per order will be after the first 12 months.
- Whether they can handle our repairs and warranty returns, which need a trained person.
- How their system would connect to our store. The proposal says "standard connection" and no more.
input/options/renew.md · 26 lines, 1 KB
# Option: renew the lease on Fallow Lane

Written by Gethin Marlowe, warehouse manager, November 20, 2026.

## What it is
Sign the landlord's new three year lease and carry on as we are. Same building, same team of 9, same
systems. The landlord's letter of November 3 puts the rent at 312,000 a year, up from 268,000.

## Why I like it
Nothing moves, so nothing breaks. The team knows the building. We ship 97 percent of orders the day
after they come in and I would not bet that number on a move.

## Risks
- The building is full. In peak season we already rent overflow space and walk stock across the yard.
- The landlord's letter says the rent can be reviewed again after 18 months.
- The roof leaked twice last winter over bays 4 and 5 and the landlord has only patched it.
- If orders grow 15 percent a year as planned we run out of pick faces some time in 2028.

## Not known yet
- Whether the landlord will fix the roof properly as a condition of the new lease.
- How much the rent could rise at the 18 month review.
- Whether the overflow unit next door will still be available to rent next summer.

## Other things people have said
At the offsite someone suggested we buy a building instead of renting. Nobody has looked into it and
there is no note on it.
input/options/split.md · 22 lines, 1 KB
# Option: outsource shipping and keep a small unit for returns

Written by Bronagh Stavros, head of customer care, November 22, 2026.

## What it is
Use the same fulfilment provider for new orders, and rent a small unit near the office for returns,
repairs and warranty work. We would keep 3 of the warehouse team to run it and one of them would
manage the provider.

## Why I like it
Repairs are why customers come back to us. A provider will not do them well. This keeps the part we
are good at and hands off the part that is only boxes.

## Risks
- We would make 5 of the 9 warehouse staff redundant.
- Stock would sit in two places and returned items would need a second trip to go back on sale.
- We would depend on the provider for peak season in the first year we work with them.
- Three people is thin cover for holidays and sickness.

## Not known yet
- Whether a small unit can be found near the office. The 78,000 rent is from one listing only.
- How many returned items a week would need to travel back to the provider.
input/question.md · 24 lines, 1 KB
# Decision needed: where orders ship from after June 30, 2027

Cragmoor Trail Goods. Raised by Winifred Asante, chief executive. To be decided at the leadership
meeting on December 14, 2026.

## Background
We sell camping and hiking gear online and ship about 96,000 orders a year from one leased warehouse
on Fallow Lane. The lease ends on June 30, 2027. The landlord has offered a new three year lease at a
higher rent and wants an answer by January 15, 2027. Peak season runs from April to August, so any
change has to be finished before April or wait until September.

## What I am asking for
Four people have each written a note on one option. I want one memo that sets the options side by
side over three years: what each costs, what could go wrong and what we still do not know. I do not
want a recommendation yet. I want to see what we would have to find out before choosing.

## What matters, in order
1. Orders keep shipping on time through peak season.
2. Total cost over three years.
3. What happens to the 9 people who work in the warehouse today.

## Files
- options/renew.md, options/move.md, options/outsource.md, options/split.md: one note for each option.
- costs.csv: the cost sheet finance keeps for this decision. One line for each cost, marked one_time or annual.
output/evidence.csv · written by the agent, 29 lines
option,kind,quote,source_file
move,risk,A move in February and March leaves no slack before peak season starts in April.,input/options/move.md
move,risk,We would run two buildings for at least two weeks and ship from both.,input/options/move.md
move,risk,Three of the 9 warehouse staff have told me the longer drive would be a problem for them.,input/options/move.md
move,risk,The unit has been empty for a year and the loading doors have not been tested.,input/options/move.md
move,unknown,What the move would cost us in lost or late orders. Nobody has estimated it.,input/options/move.md
move,unknown,Which of the two removal quotes is realistic. They differ by a wide margin.,input/options/move.md
move,unknown,Whether the agent will hold the unit until our December 14 meeting.,input/options/move.md
outsource,risk,We would make 8 of the 9 warehouse staff redundant.,input/options/outsource.md
outsource,risk,The provider ships for about 40 other brands and we would not be their largest customer.,input/options/outsource.md
outsource,risk,"Their proposal promises to ship within two working days, which is slower than what we do today.",input/options/outsource.md
outsource,risk,The fee per order is fixed for 12 months only.,input/options/outsource.md
outsource,risk,Getting stock back out is slow and costly if it does not work.,input/options/outsource.md
outsource,unknown,What the fee per order will be after the first 12 months.,input/options/outsource.md
outsource,unknown,"Whether they can handle our repairs and warranty returns, which need a trained person.",input/options/outsource.md
outsource,unknown,"How their system would connect to our store. The proposal says ""standard connection"" and no more.",input/options/outsource.md
renew,risk,The building is full. In peak season we already rent overflow space and walk stock across the yard.,input/options/renew.md
renew,risk,The landlord's letter says the rent can be reviewed again after 18 months.,input/options/renew.md
renew,risk,The roof leaked twice last winter over bays 4 and 5 and the landlord has only patched it.,input/options/renew.md
renew,risk,If orders grow 15 percent a year as planned we run out of pick faces some time in 2028.,input/options/renew.md
renew,unknown,Whether the landlord will fix the roof properly as a condition of the new lease.,input/options/renew.md
renew,unknown,How much the rent could rise at the 18 month review.,input/options/renew.md
renew,unknown,Whether the overflow unit next door will still be available to rent next summer.,input/options/renew.md
split,risk,We would make 5 of the 9 warehouse staff redundant.,input/options/split.md
split,risk,Stock would sit in two places and returned items would need a second trip to go back on sale.,input/options/split.md
split,risk,We would depend on the provider for peak season in the first year we work with them.,input/options/split.md
split,risk,Three people is thin cover for holidays and sickness.,input/options/split.md
split,unknown,"Whether a small unit can be found near the office. The 78,000 rent is from one listing only.",input/options/split.md
split,unknown,How many returned items a week would need to travel back to the provider.,input/options/split.md
output/memo.md · written by the agent, 50 lines
# Memo: where orders ship from after June 30, 2027

## Decision needed
Winifred Asante, chief executive, asks the leadership meeting on December 14, 2026 to decide where orders ship from after the Fallow Lane lease ends on June 30, 2027. The landlord wants an answer by January 15, 2027. Changes must finish before April or wait until September. Priorities: on-time peak season shipping, three year cost, then the 9 warehouse staff. No recommendation was requested, so none is made.

## Options at a glance
| Option | One time cost | Yearly cost | Three year cost | Cost complete |
|---|---|---|---|---|
| renew | 36,000 | 875,000 | 2,661,000 | yes |
| move | 212,700 | 930,000 | 3,002,700 | no |
| outsource | 190,500 | 732,400 | 2,387,700 | yes |
| split | 168,500 | 836,400 | 2,677,700 | yes |

Move is 615,000 above outsource, and its figure excludes lost sales during the move.

## Renew the lease on Fallow Lane
Sign the landlord's three year lease and carry on as now. Rent rises from 268,000 to 312,000 a year.
- **Risks:** the building is full and overflow space is rented in peak season. Rent can be reviewed after 18 months. The roof leaked twice and has only been patched. Pick faces could run out in 2028 if orders grow as planned.
- **Not known:** whether the landlord will fix the roof, how much rent could rise, and whether the overflow unit stays available.

## Move to the Kettleby Road unit
Lease a unit 6 miles away with 60 percent more floor space and four loading doors, moving in February and March 2027.
- **Risks:** no slack before April. Two buildings would run for at least two weeks. Three of the 9 staff say the drive would be a problem. The unit has been empty for a year and its doors are untested.
- **Not known:** cost of lost or late orders, which removal quote is realistic, and whether the agent will hold the unit until December 14.

## Outsource shipping to a fulfilment provider
Close our warehouse and pay Northfold Fulfilment 5.40 an order plus storage and returns fees. One person manages the account.
- **Risks:** 8 of the 9 staff made redundant. The provider serves about 40 other brands and we would not be the largest. Its promised two working day shipping is slower than today. The fee is fixed for 12 months only. Getting stock back out is slow and costly.
- **Not known:** the fee after 12 months, whether they can handle repairs and warranty returns, and how their system would connect to ours.

## Split: outsource and keep a small returns unit
Use the same provider for new orders and rent a small unit near the office for returns, repairs and warranty work, run by 3 of the team.
- **Risks:** 5 of the 9 staff made redundant. Stock in two places, and returns need a second trip. First-year peak season depends on the provider. Three people is thin cover.
- **Not known:** whether a small unit can be found (the 78,000 rent is from one listing), and how many returns a week must travel to the provider.

## Problems in the cost sheet
- **Entered twice:** L-01 and L-06 (renew, rent, 312,000). Counted once.
- **Conflicting quotes:** L-10 (38,000) and L-11 (52,500), move, moving stock and racking. I counted the higher, L-11.
- **Blank amount:** L-14 (move, lost sales). Left out, so move cost is not complete.
- **Not an option:** L-30 (buy, building deposit). No note, left out.
- **Note total differs:** move.md states about 2,960,000. I worked out 3,002,700. The outsource note's 2,387,700 matches. Renew and split notes state no total.

## Ideas raised but not worked up
Buying a building instead of renting was suggested at the offsite. There is no note on it. Its only cost line is L-30.

## What to find out before choosing
- Renew: whether the landlord will fix the roof properly as a condition of the new lease; how much the rent could rise at the 18 month review; whether the overflow unit next door will still be available next summer.
- Move: lost or late order cost (blank amount L-14); which removal quote is realistic; whether the agent will hold the unit until December 14.
- Outsource: the fee per order after the first 12 months; whether they can handle repairs and warranty returns; how their system would connect to our store.
- Split: whether a small unit can be found near the office; how many returned items a week would need to travel back to the provider.
output/options.csv · written by the agent, 5 lines
option,one_time_cost,annual_cost,three_year_cost,cost_complete,risks,unknowns
move,212700,930000,3002700,no,4,3
outsource,190500,732400,2387700,yes,5,3
renew,36000,875000,2661000,yes,4,3
split,168500,836400,2677700,yes,4,2
check.py · the check, written before the run
"""Works out each option's cost again from the cost sheet and checks every quote against the notes."""
import csv, re, sys
from pathlib import Path
root = Path(sys.argv[1]); ok = True
def say(passed, text):
    global ok; ok = ok and passed; print(("PASS " if passed else "FAIL ") + text)
def nums(text):
    return {round(float(n.replace(",", "")), 2) for n in re.findall(r"\d[\d,]*(?:\.\d+)?", text)}
def flat(s):
    s = s.replace("’", "'").replace("‘", "'").replace("“", '"').replace("”", '"')
    return re.sub(r"\s+", " ", s).strip().strip('"').strip()
def fnum(s):
    try: return float(re.sub(r"[,$\s]", "", s or ""))
    except ValueError: return None

notes = {p.stem: p.read_text() for p in sorted((root/"input/options").glob("*.md"))}
points = []  # (option, kind, text)
for opt, text in notes.items():
    kind = None
    for ln in text.splitlines():
        if ln.startswith("#"):
            h = ln.lower(); kind = "risk" if "risk" in h else "unknown" if "not known" in h or "unknown" in h else None
        elif kind and ln.strip().startswith("- "):
            points.append((opt, kind, flat(ln.strip()[2:])))
lines = list(csv.DictReader((root/"input/costs.csv").open()))
want, problems, seen = {}, [], {}
for opt in notes: want[opt] = {"one_time": {}, "annual": {}, "complete": True}
for r in lines:
    opt, key = r["option"], (r["option"], r["item"], r["type"])
    if opt not in notes: problems.append(("no note", [r["line_id"]], [])); continue
    if r["amount"].strip() == "": want[opt]["complete"] = False; problems.append(("blank", [r["line_id"]], [])); continue
    amt = float(r["amount"])
    if key in seen:
        first_id, first_amt = seen[key]
        problems.append(("twice" if first_amt == amt else "conflict", [first_id, r["line_id"]], []))
        amt = max(amt, first_amt)
    else: seen[key] = (r["line_id"], amt)
    want[opt][r["type"]][r["item"]] = amt
totals = {}
for opt, w in want.items():
    one, yearly = sum(w["one_time"].values()), sum(w["annual"].values())
    totals[opt] = (one, yearly, one + 3 * yearly, "yes" if w["complete"] else "no")
for opt, text in notes.items():
    m = re.search(r"([\d,]{7,}) over three years", text)
    if m and float(m.group(1).replace(",", "")) != totals[opt][2]:
        problems.append(("note total", [], [float(m.group(1).replace(",", "")), totals[opt][2]]))

rows = list(csv.DictReader((root/"output/options.csv").open())) if (root/"output/options.csv").exists() else []
got = {(r.get("option") or "").strip(): r for r in rows}
say(set(got) == set(notes) and len(rows) == len(notes), f"{len(set(got) & set(notes))} of {len(notes)} options with a note are in options.csv and {len(set(got) - set(notes))} options were added")
right = sum(1 for o, t in totals.items() if o in got and [fnum(got[o].get("one_time_cost")), fnum(got[o].get("annual_cost")), fnum(got[o].get("three_year_cost"))] == list(t[:3])
            and (got[o].get("cost_complete") or "").strip().lower() == t[3])
say(right == len(totals), f"{right} of {len(totals)} options have the one time, yearly and three year cost worked out again from the cost sheet")
ev = list(csv.DictReader((root/"output/evidence.csv").open())) if (root/"output/evidence.csv").exists() else []
tally = sum(1 for o in notes for col, k in (("risks", "risk"), ("unknowns", "unknown")) if o in got and fnum(got[o].get(col)) == sum(1 for po, pk, _ in points if (po, pk) == (o, k))
            == sum(1 for e in ev if ((e.get("option") or "").strip(), (e.get("kind") or "").strip()) == (o, k)))
say(tally == 2 * len(notes), f"{tally} of {2 * len(notes)} risk and unknown counts in options.csv equal the points listed in the notes and the rows of evidence.csv")
covered = sum(1 for o, k, text in points if any((e.get("option") or "").strip() == o and (e.get("kind") or "").strip() == k
              and len(flat(e.get("quote") or "")) >= 25 and flat(e.get("quote") or "").rstrip(".") in text for e in ev))
say(covered == len(points) and points, f"{covered} of {len(points)} risks and unknowns written in the notes are quoted in evidence.csv")
def in_source(e):
    p = root/(e.get("source_file") or "").strip()
    return p.is_file() and len(flat(e.get("quote") or "")) >= 10 and flat(e.get("quote") or "") in flat(p.read_text())
word = sum(1 for e in ev if in_source(e))
say(bool(ev) and word == len(ev), f"{word} of {len(ev)} quotes in evidence.csv are word for word in the note they name")
memo = (root/"output/memo.md").read_text() if (root/"output/memo.md").exists() else ""
inputs_text = "".join(p.read_text() for p in sorted((root/"input").rglob("*")) if p.is_file())
allowed = nums(inputs_text) | {v for t in totals.values() for v in t[:3]} | {abs(a[2] - b[2]) for a in totals.values() for b in totals.values()}
figs = [n for n in nums(re.sub(r"\bL-\d+\b", " ", memo)) if n >= 1000]
traced = sum(1 for n in figs if n in allowed)
say(len(figs) >= 8 and traced == len(figs), f"{traced} of {len(figs)} figures of 1,000 or more in memo.md trace to the cost sheet, the notes or the worked out totals")
FIG = r"(?<![\w.-])\d(?:[\d,]*\d)?(?:\.\d+)?(?![\w-])"
def figs(text): return {round(float(x.replace(",", "")), 2) for x in re.findall(FIG, text)}
real = set()  # figures as a reader sees them: no line ids
for p in sorted((root/"input").rglob("*")):
    if p.suffix == ".csv":
        for row in csv.reader(p.open()):
            for cell in row: real |= figs(cell)
    elif p.is_file(): real |= figs(p.read_text())
small = [n for n in figs(memo) if n < 1000 and (n >= 10 or n != int(n))]
s_ok = sum(1 for n in small if n in real)
say(s_ok == len(small) and small, f"{s_ok} of {len(small)} figures under 1,000 in memo.md are printed in the question, a note or the cost sheet")
mn = nums(memo)
found = sum(1 for _, ids, vals in problems if all(re.search(rf"\b{i}\b", memo) for i in ids) and all(v in mn for v in vals))
say(found == len(problems) and problems, f"{found} of {len(problems)} problems in the cost sheet are named in memo.md with their line ids or both figures")
words = len(memo.split())
say(0 < words <= 800, f"memo.md is {words} words, inside the 800 word limit")
sys.exit(0 if ok else 1)

costs.csv: sample data written by Atris. Fingerprint a49ebb769ae6.

move.md: sample data written by Atris. Fingerprint 07499b70483f.

outsource.md: sample data written by Atris. Fingerprint 691756c82bf5.

renew.md: sample data written by Atris. Fingerprint b1c6b6512e1a.

split.md: sample data written by Atris. Fingerprint 54622911504d.

question.md: sample data written by Atris. Fingerprint 0a2d1600ca6a.

evidence.csv: written by the agent. Fingerprint 59cb0791e489.

memo.md: written by the agent. Fingerprint d5210c5b0f28.

options.csv: written by the agent. Fingerprint 8a7a21f42497.


More the founder's office work, and every other desk job

For agentsGitHub
What is AtrisBlogApp StorePricingPrivacyTerms