acikpoz
Copilot instructions1 starsChanged 4 months agoMITView on GitHub
Deterministic, offline Python tool that turns Turkish public-construction unit-price (ÇŞB birim fiyat) catalog PDFs into structured Poz records (code, description, unit, price), with year-over-year diff and validation, exposed as a CLI and an optional MCP server. Managed with uv (uv.lock committed); Python ≥3.10, hatchling build backend. These are the exact CI commands (.github/workflows/ci.yml): Run the tools: acikpoz parse FILE.pdf --pages 8-20 (also diff OLD.pdf NEW.pdf, validate FILE.pdf; --json/--csv/--group/--priced-only). MCP server entry point: acikpoz-mcp. src/ layout, one package src/acikpoz/. The pipeline…
The file
We split this copilot-instructions.md into the rules it gives an agent
2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 17
Run the tools: acikpoz parse FILE.pdf --pages 8-20 (also diff OLD.pdf NEW.pdf, validate FILE.pdf.
- Very specific: line 33
Every module starts with from __future__ import annotations and uses X | None types.
≈ “Common” is an estimate: at least 1 in 5 of the 1,644 Copilot instructions files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Copilot instructions — acikpoz
Deterministic, offline Python tool that turns Turkish public-construction unit-price (ÇŞB birim fiyat) catalog PDFs into structured Poz records (code, description, unit, price), with year-over-year diff and validation, exposed as a CLI and an optional MCP server.
Build, test, lint
Managed with uv (uv.lock committed); Python ≥3.10, hatchling build backend. These are the exact CI commands (.github/workflows/ci.yml):
uv sync --dev --extra mcp # install core + dev tools + optional mcp extra
uv run pytest -q # tests (config in [tool.pytest.ini_options], testpaths=tests)
uv run ruff check src tests # lint
uv run mypy src # type-check
uv build # build sdist/wheel (release.yml; publishes to PyPI on v* tags via OIDC)Run the tools: acikpoz parse FILE.pdf --pages 8-20 (also diff OLD.pdf NEW.pdf, validate FILE.pdf; --json/--csv/--group/--priced-only). MCP server entry point: acikpoz-mcp.
Architecture
src/ layout, one package src/acikpoz/. The pipeline is layered so parsing logic is testable without a real PDF:
model.py—Pozdataclass; every possibly-missing field isOptional, defaulting toNone.parser.py— coordinate/geometry parser, no ML. Pureparse_words(word_dicts)->parse_page(page)->parse_catalog(path, pages); reads the price-column x from the page header;ParseResultreports coverage (priced/group_headers/gaps,price_parse_rate,grade);tl()parses Turkish money ("1.310,00" -> 1310.0).diff.py—diff_pozes->CatalogDiff/PozChange(kinds: price_change/unit_change/added/removed/now_priced/now_unpriced).validate.py—validate_pozes->ValidationReport/Finding; deterministic rules only, error vs warning severity, never mutates data.cli.py(typer + rich, entryacikpoz) andmcp_server.py(FastMCP, entryacikpoz-mcp) are thin wrappers: tool functions return plain dicts and know nothing about the runtime.__init__.pyis the public API surface.
Conventions
- Honesty rule (core invariant): a price is only ever a number the catalog printed in the price column — never coerce, borrow a neighbour's, or guess. A missing price is
None, never0. A category-title poz (description ends:) isis_group_header=Truewithfiyat=None, counted as a header, not a gap. Preserve this in any change. - Header-driven column detection must survive the two-price-column Sıhhi Tesisat layout (real Birim Fiyat vs Montaj Bedeli) — the canonical trap covered in
tests/test_parser.py. - Tests drive the parser with synthetic pdfplumber word dicts via the
w(text, x0, top)helper; add cases there — no real PDF needed. Never commit catalog PDFs (.gitignoreblocks*.pdf); the repo ships the parser, not the data. - Every module starts with
from __future__ import annotationsand usesX | Nonetypes. mypy enforcesdisallow_untyped_defsandno_implicit_optional(all defs typed). ruff: line-length 100, target py310, rulesE,F,I,UP,B,SIM,RET,C4. --pagesis 0-based. CSV output isutf-8-sig(Excel + Turkish), JSON isensure_ascii. Keep themcpimport optional and runtime-guarded — out of the core dependency set.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

