Adds specifications for submodules and build targets.#240
Conversation
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Written to the actual code: SolverContext is a single-header class with per-SearchContext-owned TT (no SolverContextImpl / include-split, no ThreadData-owned TT), deviating from the task's assumed layout. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Bindings are hand-written FFM (not jextract-generated) per the actual code; spec reflects that. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
@tameware , here are the spec files that I mentioned earlier today. I have had a quick read through them and they make sense to me. As you can see I asked claude code to generate them. My suggestion would be that you check out this branch and see if cursor agrees that they are useful. My view is that next steps for what we want to do with |
|
Makes perfect sense. I'll ask Cursor to have a look now. |
|
First look by Cursor. I'll add its proposed changes in my next comment. Also, this is the default Cursor model. I can apply a higher-powered one if you think it might be useful. Copilot generated the specs added in this branch. Do they make sense? Mostly yes — as agent-facing capability docs they have the right shape. Not yet trustworthy as source of truth without a pass for concrete wrong claims. They follow the template well: purpose, cross-cutting invariants, entry points, non-goals. Coverage matches real subsystems (API layers, context ownership, TT, moves, concurrency, bindings, build, web). Strongest: Where they break down is accuracy and a few litmus slips: Real code mismatches
Template / process nits
Bottom line: sensible first draft for PR #240’s goal (give agents capability context doxygen can’t). Treat as drafts that need a fact-check pass before agents rely on them. I can land fixes for the mismatches above if you want. |
|
Cursor made its proposed fixes in my local repo. Shall I submit them as updates to this PR, make a new PR, or paste the diffs here? |
|
I suggest that you push the updates to this branch. I'll download them and ask claude to do a code review with a high power model. |
Fix ownership, ABI, lifecycle, and test-suite claims that did not match the tree, and drop the placeholder related-plans entries. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Pushed. |
Prepare the specs for a public repository and correct the factual errors found by a cold-context review of the branch. Public-repo readiness: - Remove the `related-plans` front-matter field from all 15 specs and from the template; the public repo carries no plans. - Reword the template's "keep these current" bullet, which referenced the internal `action-tasks` workflow and a plan's "Spec impact" section. - Convert 70 `[[wiki-link]]` cross-references to standard markdown links. GitHub renders the wiki form as literal text. Correctness: - solver-context: `clear_tt()` does not leave a reusable table. It deallocates the table's storage and nothing re-runs `make_tt()` (`SearchContext::trans_table()` returns early on non-null `tt_`, and `TransTable::init()` allocates nothing), so a context reused afterwards degrades to a silently dead cache. Document that and point at `dispose_trans_table()`. No test guards this. - transposition-table: state that `return_all_memory()` requires `make_tt()` before reuse, matching the header contract. - dds-public-api: only `dds_calc_dd_table` has a `*PBN` twin on the modern C++ layer; drop the `-> int` from the flat-layer signature sketch, since `SetMaxThreads`/`SetResources`/`FreeMemory` return void. - ab-stats: `solver_if.cpp` uses `ABStats` directly, not via `AB_COUNT`. - build-system: `build_windows` also requires `@platforms//cpu:x86_64`, so Windows-arm64 falls through to `//conditions:default`. - lookup-tables: `gap_` is valid for indices 1..last_group_, not 0.. - examples-cli: the `all_examples_wasm` alias is unconditional. - tt_context_ownership is inert (no source `#ifdef`s it) and is applied to one test target, where it likewise has no effect. - Use `//pkg/...` form for test package labels; the bare labels do not name real targets for moves and heuristic_sorting. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Pushed updates from Claude's review. It did not find anything major. The references to plans are related to my local workflow. |
|
Looks like we will have only a couple of nits if we do one more back and forth between Cursor and Claude. |
Correct which layers each binding uses, clear_tt reuse hazards, TT-S memory limits, heuristic source of truth, and malformed order fallback. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Pushed changes courtesy of Grok 4.5 High Fast: Mostly solid after the fact-check commits. Shape and coverage are right for agent context; a few remaining factual errors still matter. Still wrong / risky
Minor
Clean enough
|
Address local review findings against the actual sources: - transposition-table: reset_memory() bumps the per-reason reset counters rather than clearing statistics, which accumulate by design; note TransTableS's counters are gated on DDS_TT_STATS while TransTableL's are unconditional. - transposition-table: the header documents a 0 default limit as "unlimited", but TransTableL yields pages_default_ == 0 and the next reset then frees every pooled page. Record 0 as unsupported and mark the doxygen claim as untrue rather than restating it. - python-binding: name initialise_static_memory as the current API and flag set_max_threads as a deprecated, argument-ignoring alias. - dds-public-api: adopt testable_dds_util_log / _stats, which build from testable_dds_sources and differ only by their _log / _stats deps, leaving no build target without an owning spec. - build-system: owners now names the real roots rather than the unlookupable "build-root". Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Pushed one medium and four nits identified by claude using opus 4.8. |
|
LGTM |
Coding agents cannot extract the purpose of a module or build target just from the code and documentation. Adding specs to the repository aims to give them this extra context. Specs should be treated as live documents, they need to be updated as requirements evolve.