Skip to content

Decisions

Vitor edited this page Dec 3, 2026 · 1 revision

botticelli

Decisions

Status: built (M0). Four decisions are recorded, all accepted. A tradeoff written in an ADR is by design.

In one minute

An ADR (architecture decision record) is a short file in docs/adr/ that says what was decided, why, and what it costs. This page lists them. Read the ADR before you change the code it governs. Change a decision with a new ADR, not with a quiet code change.

Index

No. Title Status Decision File
0001 One adapter per source behind a common Source interface accepted (2026-12-02) Every source is an adapter in src/sources/<id>/ that implements Source and returns Refs. The pipeline, the Library and the server only see Refs and Sources 0001-source-adapters.md
0002 Pinterest is read through its web endpoints, not the official API accepted (2026-12-02) Use the web resources at a modest request rate with ads filtered out, design resilience in from the start, and keep downloads for reference only with their origin in a Sidecar 0002-scraping-and-terms.md
0003 No native dependencies accepted (2026-12-02) Decode and encode images in pure JS (jpeg-js, pngjs). playwright-core is optional, loaded lazily, and never downloads a browser on install 0003-no-native-deps.md
0004 Login is optional and opt-in, through a cookie file accepted (2026-12-02) Anonymous by default. A session is used only when BOTTICELLI_PINTEREST_COOKIE_FILE points to a cookie file that group and others cannot read. The cookie never appears in logs, errors or tool output 0004-optional-login.md

Where each one shows up:

How to write an ADR

Write one when a decision is hard to reverse, or when others will ask why. A new Source that decides something (how it logs in, what it is allowed to read) is a good case.

  1. Take the next number. The file is docs/adr/NNNN-short-title.md, numbered in order, with a short lower-case title.
  2. Use this shape. It is the shape of the four ADRs above:
# NNNN. Title in one line, as a statement

Status: accepted (YYYY-MM-DD)

## Context
What forced the decision. The facts, the constraint, what was measured and when.

## Decision
- What we do. One point per rule.
- Say what we do not do, when that is the part people will ask about.

## Consequences
- What gets easier, and what gets harder or slower.
- What the tests, the docs or the code must now do.
  1. Keep it short. The four existing ADRs are under 25 lines each. Use the terms of CONTEXT.md exactly.
  2. Add a row to the table above, in the same pull request. Link the ADR from the doc page and the code comment that depend on it.
  3. To change a decision, write a new ADR that supersedes the old one. Change the old file's Status: line to superseded by NNNN (YYYY-MM-DD) and leave the rest of it as it was. No ADR has been superseded yet.
  4. Commit it with the scope docs, for example docs(docs): add ADR 0005 for the Are.na token.

The rules for ADRs are also in CONTRIBUTING.md.

Troubleshooting / FAQ

Can I argue with an ADR? Yes. Open an issue with the new facts. If the decision changes, it changes through a new ADR.

Is a code comment enough for a decision? Not when others will ask about it. A comment says what the code does. An ADR says why the choice was made and what it costs.

Clone this wiki locally