# Search local Markdown and inspect exact evidence

A reproducible Capicove walkthrough | 8 November 2026

A keyword result is more useful when you can inspect the passage that matched. This walkthrough imports three Markdown files, builds a local index, searches for a keyword and opens the exact source evidence. It also checks what happens when the input changes after import.

## Download the reproduction files

[Download the reproduction bundle](https://capicove.ai/examples/markdown-search-2026-11-08/capicove-markdown-search-2026-11-08.zip) · [SHA-256 checksums](https://capicove.ai/examples/markdown-search-2026-11-08/SHA256SUMS.txt)

The ZIP contains the exact input notes, replay script, captured output and checksums. Install the pinned public source first, then run the bundled script in a fresh directory.

## The input and the recorded environment

The three notes are authored examples summarizing linked public Capicove documentation. They are not customer documents or a claim of a real customer trial. The files and the commands below were actually executed, not simulated.

| File | What it contains |
| --- | --- |
| offline-search.md | SQLite FTS5 and the source-evidence workflow |
| platform-scope.md | Linux qualification and the pending native macOS boundary |
| release-notes.md | The 0.1.0 public source release and installation boundary |

Recorded environment: macOS 26.6.2 arm64; Capicove 0.1.0; CLI Python 3.11.14; SQLite 3.50.4 with FTS5. A separate Python 3.14.2 process drove the replay script. The public capability matrix qualifies Linux and still lists native macOS qualification as pending. This one macOS run does not change that status.

## Install the same public source snapshot

Requires Python 3.11+ and uv. Installation can access the network. No model download, hosted API or API key is needed for the demonstrated retrieval commands.

```text
git clone https://github.com/happyBayes/capicove.git
cd capicove
git checkout 3f1be3314fa15dec8b8063166d77cc896cc5f68f
uv sync --locked --no-dev --python 3.11
```

Unzip the accompanying reproduction bundle. From that folder, run the following with the absolute executable path from your checkout. Choose a new output directory.

```text
python3 reproduce.py \
  --capicove /absolute/path/capicove/.venv/bin/capicove \
  --out /absolute/path/new-markdown-case
```

On macOS the runner applies an OS sandbox denying network access to each Capicove invocation. On other systems it records that OS-level denial was not enforced; the workspace configuration still disables network access.

## Follow the CLI path

The bundle includes the three exact input files. Set BIN to your installed executable and CASE to a new absolute path. Copy the bundled notes directory to "$CASE/notes" before setup.

```text
BIN=/absolute/path/capicove/.venv/bin/capicove
CASE=/absolute/path/new-markdown-case
mkdir -p "$CASE"
cp -R notes "$CASE/notes"
"$BIN" setup init "$CASE/workspace" \
  --source-root "notes=$CASE/notes"
CFG="$CASE/workspace/host.json"
"$BIN" setup doctor --config "$CFG"
for NAME in offline-search.md platform-scope.md release-notes.md; do
  "$BIN" source import --runtime-config "$CFG" \
    --root notes --relative-path "$NAME"
done
"$BIN" index build --runtime-config "$CFG"
"$BIN" search FTS5 --runtime-config "$CFG"
```

The observed build activated one generation containing 3 sources and 3 text units. The FTS5 query returned 1 hit from notes/offline-search.md. Copy the evidence_id from that hit and open its metadata and lineage:

```text
"$BIN" get-evidence YOUR_EVIDENCE_ID --runtime-config "$CFG" \
  --section metadata --section lineage
```

### What the captured evidence showed

```text
source_ref: notes/offline-search.md
start_char: 0
end_char: 403
source_sha256:
49f185bc7e04bcd8786c836a9fc0c2a12cc31760e5dd4360dcaff4dcafd85fa6
text begins:
# Offline Markdown search

SQLite FTS5 provides keyword search over imported Markdown...
```

These are selected fields from the captured JSON, with the text shortened for this page. The full JSON and exact text are in the reproduction bundle.

The independent check compared metadata.text with the original UTF-8 file at [start_char:end_char]. It matched exactly. A separate SHA-256 calculation over the complete source file matched both metadata.source_sha256 and lineage.source_sha256. Character offsets and byte length are different fields: this file has 404 bytes, while the returned span ends at character 403 because the final newline is outside the chunk.

## Check the boundaries, not just the hit

| Check | Observed result |
| --- | --- |
| Query qzxnomatch83917 | Succeeded with an empty hits list |
| Re-import unchanged offline-search.md | changed: false |
| Build again with unchanged inputs | The generation ID stayed the same |
| Append text after import, then build | Build rejected the changed source; no replacement generation activated |
| Restore the source and search again | The prior evidence ID remained searchable |
| Deny network with the macOS sandbox | The retrieval commands succeeded; a control socket request was denied |

The complete runner was then replayed in a fresh directory. It passed the import, build, exact-source comparison and failure-path checks again. Request IDs and temporary paths can differ between runs. Do not use this tiny example as a speed benchmark or a general accuracy evaluation.

## What this gives a reader

The result is a local keyword search with inspectable evidence. A reader can check the returned passage, source identity, recorded hash and index generation. It is not semantic search or an LLM-generated answer, and a matching passage does not by itself prove that a broader claim is correct.

## Limits worth keeping visible

This test uses three small English notes. It does not test large collections, multilingual recall, media processing, browser interactions, MCP clients, Windows or full Linux/macOS release qualification. The documented tokenizer has limited recall for languages written without spaces. Dependencies were installed before the offline run. The homepage remains an interactive concept demo; use the public source checkout and documentation to run the real workflow.

## Run it and inspect the evidence

The accompanying reproduction bundle contains the exact notes, reproduce.py, captured stdout/stderr and the verification results. Run the script in a fresh directory, then inspect result.json and the captured evidence.

AI assistance was used to prepare the example and this text. The commands and evidence comparisons were executed locally.

### Sources

Pinned public source: https://github.com/happyBayes/capicove/tree/3f1be3314fa15dec8b8063166d77cc896cc5f68f

Offline workspace guide: https://capicove.readthedocs.io/en/latest/guides/offline-retrieval/

Capability matrix: https://capicove.readthedocs.io/en/latest/getting-started/capabilities/
