migrate: 17 memories moved to strat-gameplay
This commit is contained in:
parent
b5fe9bb696
commit
796b88ca4a
@ -6,13 +6,7 @@ tags: [claude-code, agent-teams, tmux, settings, claude-home, configuration]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-26T18:14:54.211526+00:00"
|
||||
updated: "2026-02-28T05:06:36.910547+00:00"
|
||||
relations:
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: REQUIRES
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 600e028b-6ee2-4413-b35c-220d210fb8fd
|
||||
updated: "2026-03-01T22:02:57.288962+00:00"
|
||||
---
|
||||
|
||||
# Claude Code Agent Teams configuration
|
||||
@ -42,3 +36,4 @@ claude --teammate-mode tmux
|
||||
|
||||
## Prerequisite
|
||||
Must be inside a tmux session. Use the `cc()` alias in ~/.zshrc to auto-create named sessions.
|
||||
|
||||
|
||||
@ -6,13 +6,7 @@ tags: [rust, cargo, fish, configuration, workstation, rustup]
|
||||
importance: 0.4
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T16:53:17.852372+00:00"
|
||||
updated: "2026-02-28T16:53:55.359039+00:00"
|
||||
relations:
|
||||
- target: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.6
|
||||
edge_id: 1a8007be-890d-4ca2-9c8e-d9bd35c9cb79
|
||||
updated: "2026-03-01T22:02:57.289708+00:00"
|
||||
---
|
||||
|
||||
# Rust Toolchain Setup
|
||||
@ -36,3 +30,4 @@ Rustup auto-configures fish via `~/.config/fish/conf.d/` so this may already be
|
||||
## Build Cache
|
||||
|
||||
Cargo stores compiled artifacts in `target/` directory. Incremental builds only recompile changed files, so subsequent builds are significantly faster than the first.
|
||||
|
||||
|
||||
@ -1,78 +0,0 @@
|
||||
---
|
||||
id: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
type: decision
|
||||
title: "SBA Scout Python-to-Rust TUI migration: recommended stack and approach"
|
||||
tags: [sba-scout, rust, migration, ratatui, research, decision, tui]
|
||||
importance: 0.7
|
||||
confidence: 0.8
|
||||
created: "2026-02-23T18:05:05.367031+00:00"
|
||||
updated: "2026-02-28T16:53:58.777098+00:00"
|
||||
relations:
|
||||
- target: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: BUILDS_ON
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: 5cde624d-cbf0-456b-aa87-076e7e999dde
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.7
|
||||
edge_id: b8e47bac-8b05-4e2c-b0a0-bd7683ced31f
|
||||
- target: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 0dfd7245-6d94-4a78-84a8-dae22a15fbb1
|
||||
- target: 1768d9ab-0c21-4ec3-bb04-bd70366f6240
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.7
|
||||
edge_id: 8b24bed4-38a2-4a70-8b5e-de2782c897e0
|
||||
---
|
||||
|
||||
# SBA Scout Python-to-Rust TUI Migration Research
|
||||
|
||||
## Context
|
||||
|
||||
SBA Scout is a Python TUI app using Textual + SQLAlchemy + httpx + pydantic-settings. Research was conducted to evaluate converting it to Rust.
|
||||
|
||||
## Recommended Stack (Option A - Lean and Idiomatic)
|
||||
|
||||
- **UI:** ratatui 0.30 + crossterm
|
||||
- **Async runtime:** tokio
|
||||
- **Database:** sqlx 0.8.6 (sqlite, async)
|
||||
- **HTTP client:** reqwest 0.12.28
|
||||
- **Config:** figment 0.10.19
|
||||
- **Serialization:** serde + toml
|
||||
- **Math:** pure f64 (no external crate needed)
|
||||
- **Rust edition:** 2024
|
||||
|
||||
## Alternative Stack (Option B - Higher Abstraction)
|
||||
|
||||
- **UI:** tui-realm 3.3 on top of ratatui
|
||||
- **Config:** config-rs 0.15.19 with YAML
|
||||
|
||||
## Rejected Libraries
|
||||
|
||||
- **Diesel:** rejected — no async SQLite support
|
||||
- **rusqlite:** rejected — sync only, not Send
|
||||
- **serde_yaml:** deprecated — migrate config to TOML instead of YAML
|
||||
|
||||
## Migration Order
|
||||
|
||||
1. Data structs (models)
|
||||
2. sqlx queries (database layer)
|
||||
3. API client (reqwest)
|
||||
4. Config (figment)
|
||||
5. First screen: Roster (screens layer)
|
||||
6. Iterate remaining screens
|
||||
|
||||
## Key Challenges
|
||||
|
||||
- Calc layer is the easiest port (pure math, f64)
|
||||
- Screens are the hardest: ratatui is immediate-mode (draw loop), while Textual is retained-mode (component tree with reactive state)
|
||||
- Async patterns differ significantly between Python and Rust
|
||||
|
||||
## Reference
|
||||
|
||||
Full research saved to NoteDiscovery at `projects/sba-scout/rust-tui-migration-research`.
|
||||
@ -1,74 +0,0 @@
|
||||
---
|
||||
id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: decision
|
||||
title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
tags: [sba-scout, rust, tui, ratatui, phase-4, async, tokio, decision]
|
||||
importance: 0.8
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T16:52:43.969652+00:00"
|
||||
updated: "2026-02-28T16:54:00.365432+00:00"
|
||||
relations:
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: 0868f506-7c16-49a6-8d1c-0ced9d74a9cc
|
||||
- target: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: 915d9199-dab1-401f-81ec-34de8e1d1eb8
|
||||
- target: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 0dfd7245-6d94-4a78-84a8-dae22a15fbb1
|
||||
- target: 1768d9ab-0c21-4ec3-bb04-bd70366f6240
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: d07fb339-8eb5-40c8-b63c-fcce499f0fc3
|
||||
- target: baa10a3d-8ec9-4a5b-bb1c-1c80f265473f
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.6
|
||||
edge_id: 1a8007be-890d-4ca2-9c8e-d9bd35c9cb79
|
||||
- target: 49a8001d-b3b9-4a29-911a-956db4b37f21
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.7
|
||||
edge_id: 6f4bc010-3d87-484c-b762-e700036a6b1f
|
||||
---
|
||||
|
||||
# SBA Scout Rust Phase 4 Complete
|
||||
|
||||
**Branch:** `feat/rust-rewrite` | **Commit:** `6d2b11a`
|
||||
|
||||
## What Was Implemented
|
||||
|
||||
Phase 4 replaced blocking `event::read()` with `tokio::select!` over `EventStream` + mpsc channel + tick interval, enabling a fully async TUI.
|
||||
|
||||
## Architecture
|
||||
|
||||
- **AppMessage enum** — typed channel messages for background task results
|
||||
- **ActiveScreen enum** — owns screen-specific state (`DashboardState`, `GamedayState`)
|
||||
- **SelectorWidget<T>** — generic popup list widget for cascading selectors
|
||||
- **Notification system** — UI notifications with auto-expiry
|
||||
|
||||
## Screens
|
||||
|
||||
### Dashboard
|
||||
- Roster summary cards
|
||||
- API sync trigger
|
||||
|
||||
### Gameday
|
||||
- Cascading team/pitcher selectors
|
||||
- Matchup analysis table
|
||||
- 9-slot lineup management with save/load
|
||||
|
||||
## Navigation
|
||||
- `d` = Dashboard, `g` = Gameday, `q` = quit (disabled during text input)
|
||||
|
||||
## Stats
|
||||
- 1739 lines added across 10 files
|
||||
- 105 tests passing
|
||||
@ -1,37 +0,0 @@
|
||||
---
|
||||
id: c7aab060-25b8-4128-a661-eefad9dc4674
|
||||
type: decision
|
||||
title: "SBA Scout Rust Phase 6: stat weights configurable via TOML settings"
|
||||
tags: [sba-scout, rust, configuration, phase-6, calc, weights, toml, figment]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-27T01:18:26.984962+00:00"
|
||||
updated: "2026-02-27T01:19:08.017996+00:00"
|
||||
relations:
|
||||
- target: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: REQUIRES
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 92d0e814-2cc0-4622-913c-8b92ad3f280d
|
||||
---
|
||||
|
||||
# SBA Scout Rust — Phase 6 Configuration Decision
|
||||
|
||||
## Decision
|
||||
Cal requested that batter and pitcher stat weight constants be made configurable via the TOML settings file rather than hardcoded in source.
|
||||
|
||||
## Current State (Phase 1)
|
||||
Weights are hardcoded as `BATTER_WEIGHTS` and `PITCHER_WEIGHTS` arrays in `calc/weights.rs`.
|
||||
|
||||
## Planned Phase 6 Change
|
||||
- Expose standardized scoring weights in `settings.toml`
|
||||
- Load via `figment` config pipeline (already used for other settings)
|
||||
- Allows tuning matchup scoring weights without recompiling
|
||||
|
||||
## Context
|
||||
- Python SBA Scout has a `RatingWeights` in `config.py` for legacy composite ratings — this is the Rust equivalent for the standardized scoring system
|
||||
- Standardized scores use a -3 to +3 range based on league averages/stdev
|
||||
- Handedness-aware: `vLHP`/`vRHP` for batters, `vLHB`/`vRHB` for pitchers
|
||||
|
||||
## Repository
|
||||
- Repo: `sba-scouting`, branch `feat/rust-rewrite`, subdir `rust/`
|
||||
@ -1,66 +0,0 @@
|
||||
---
|
||||
id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: decision
|
||||
title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
tags: [sba-scout, rust, migration, phase-1, sqlx, sqlite, figment, decision]
|
||||
importance: 0.8
|
||||
confidence: 0.8
|
||||
created: "2026-02-27T01:18:18.061642+00:00"
|
||||
updated: "2026-02-28T16:53:45.555855+00:00"
|
||||
relations:
|
||||
- target: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
type: BUILDS_ON
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: 5cde624d-cbf0-456b-aa87-076e7e999dde
|
||||
- target: c7aab060-25b8-4128-a661-eefad9dc4674
|
||||
type: REQUIRES
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 92d0e814-2cc0-4622-913c-8b92ad3f280d
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 1.0
|
||||
edge_id: 6dc75271-96a2-43f4-ad96-cfc26ce126c1
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 10efe7b8-fe41-4e80-8733-e65add502655
|
||||
- target: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: 915d9199-dab1-401f-81ec-34de8e1d1eb8
|
||||
- target: 49a8001d-b3b9-4a29-911a-956db4b37f21
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 38d8bd6e-af74-4d93-9c35-709865f12f2f
|
||||
---
|
||||
|
||||
# SBA Scout Rust Rewrite — Phase 1 Foundation Complete
|
||||
|
||||
## Status
|
||||
Phase 1 (Foundation) committed as `2005307` on branch `feat/rust-rewrite`.
|
||||
|
||||
## What Was Implemented
|
||||
|
||||
- **Schema creation** (`schema.rs`): raw `sqlx` queries creating all 9 tables with proper constraints. Reviewer caught a missing `UNIQUE` constraint on `lineups.name` — fixed before commit.
|
||||
- **Query functions** (`queries.rs`): 20 async query functions covering teams, players, cards, lineups, sync status, matchup cache, and roster aggregates.
|
||||
- **Config integration** (`main.rs` / `app.rs`): `figment` crate used to load TOML config.
|
||||
- **Added crates**: `csv`, `sha2`, `regex` for later phases.
|
||||
|
||||
## Key Architectural Decisions
|
||||
|
||||
| Decision | Rationale |
|
||||
|---|---|
|
||||
| No ORM — sqlx pool directly | Avoid session pattern complexity; sqlx macros give compile-time query checking |
|
||||
| Separate queries for player + cards (not JOINs) | Simpler, more composable; avoids N+1 differently |
|
||||
| `ON CONFLICT` for upserts | SQLite idiomatic upsert pattern |
|
||||
| TOML config (not YAML) | Python side uses YAML but Rust ecosystem prefers TOML; figment handles both |
|
||||
|
||||
## Repository
|
||||
- Repo: `sba-scouting`, branch `feat/rust-rewrite`, subdir `rust/`
|
||||
- Language: Rust, async runtime: Tokio, DB: sqlx + SQLite
|
||||
@ -1,79 +0,0 @@
|
||||
---
|
||||
id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: decision
|
||||
title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
tags: [sba-scout, rust, migration, phase-2, reqwest, api, csv, serde]
|
||||
importance: 0.8
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T04:57:59.820017+00:00"
|
||||
updated: "2026-02-28T18:10:11.310671+00:00"
|
||||
relations:
|
||||
- target: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 1.0
|
||||
edge_id: 6dc75271-96a2-43f4-ad96-cfc26ce126c1
|
||||
- target: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: f57f63b8-1a05-4645-a320-4b045569ff55
|
||||
- target: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
type: CAUSES
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 235a68a1-bb13-43e0-9784-4b8561f7685a
|
||||
- target: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.7
|
||||
edge_id: b8e47bac-8b05-4e2c-b0a0-bd7683ced31f
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: c32c4588-17b5-4f00-8d59-37bf89c6f6be
|
||||
- target: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: 0868f506-7c16-49a6-8d1c-0ced9d74a9cc
|
||||
- target: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 5df40dff-4569-4471-96e7-fe1234d93b36
|
||||
- target: d5b6584e-ae9d-4462-aeb0-eac103156dfc
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 5fb91cf0-1aa3-4e71-af81-29c1e43730a9
|
||||
- target: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
type: FOLLOWS
|
||||
direction: incoming
|
||||
strength: 0.85
|
||||
edge_id: 03a7fade-b537-4461-b7bc-91193bb2f304
|
||||
---
|
||||
|
||||
# SBA Scout Rust Rewrite — Phase 2 Complete
|
||||
|
||||
Phase 2 (API Client + Sync + CSV Import) committed as `3c70ecc` on branch `feat/rust-rewrite`. 1,580 lines across 6 files.
|
||||
|
||||
## Files Implemented
|
||||
|
||||
- **`api/types.rs`** (175 lines): Serde response types with `#[serde(rename)]` for API field mismatches (`sname`→`short_name`, `wara`→`swar`, `gmid`→`gm_discord_id`, etc.)
|
||||
- **`api/client.rs`** (225 lines): `ApiError` enum (Http/CloudflareBlocked/Request/Parse) + `LeagueApiClient` with core `get<T>()` and 10 endpoint methods
|
||||
- **`api/sync.rs`** (243 lines): `sync_teams` (INSERT OR REPLACE), `sync_players` (ON CONFLICT omitting `hand` to preserve CSV data), `sync_transactions` (ON CONFLICT on composite key), `sync_all` orchestrator
|
||||
- **`api/importer.rs`** (666 lines): `parse_float`/`parse_int`/`parse_endurance` helpers, `import_batter_cards` (30+ column mapping), `import_pitcher_cards` (different header names, endurance parsing), `import_all_cards` (resilient — tries both CSVs independently)
|
||||
|
||||
## Key Decisions
|
||||
|
||||
- **Serde rename**: `#[serde(rename = "...")]` handles API field name mismatches at deserialization layer — cleaner than manual mapping
|
||||
- **sync_players ON CONFLICT**: Uses `DO UPDATE SET ... (excluding hand column)` to preserve hand data from CSV imports while updating all other fields from API
|
||||
- **import_all_cards resilience**: Doesn't abort if one CSV is missing — tries both independently so partial data is still loaded
|
||||
- **response.text() + serde_json::from_str()**: Used instead of `response.json()` to properly populate `ApiError::Parse(serde_json::Error)` variant (see related fix memory)
|
||||
|
||||
## Relates To
|
||||
|
||||
- Phase 1 decision: c9add129 (foundation layer — DB schema, queries, config)
|
||||
- Branch: `feat/rust-rewrite`
|
||||
@ -1,39 +0,0 @@
|
||||
---
|
||||
id: 71261e95-805e-44a0-8ee2-4a0f683dbc1f
|
||||
type: decision
|
||||
title: "SBA Scout Rust: two separate databases for Rust vs Python apps"
|
||||
tags: [sba-scout, rust, database, architecture, sqlite, migration]
|
||||
importance: 0.65
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T18:09:49.826680+00:00"
|
||||
updated: "2026-02-28T18:10:05.594987+00:00"
|
||||
relations:
|
||||
- target: ad48fe50-12a6-4c65-a49c-3a691d75e03f
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.85
|
||||
edge_id: 594e81c0-2c76-4412-8513-157d7daa92e3
|
||||
---
|
||||
|
||||
# SBA Scout Rust: two separate databases for Rust vs Python apps
|
||||
|
||||
## Decision
|
||||
|
||||
The Rust rewrite maintains its own independent SQLite database, separate from the Python app.
|
||||
|
||||
| App | DB Path | Size (approx) |
|
||||
|--------|-------------------------------|-------------------|
|
||||
| Python | `data/sba_scout.db` | 1.7 MB (full) |
|
||||
| Rust | `rust/data/sba_scout.db` | 491 KB (initial, grows after import) |
|
||||
|
||||
Both paths are relative to the repo root. The Rust app's `config.rs` defaults `db_path` to `data/sba_scout.db` relative to `cwd`, which resolves to `rust/data/sba_scout.db` when running from the `rust/` directory.
|
||||
|
||||
## CSV Import Paths (Rust)
|
||||
|
||||
Default paths (relative to `rust/` cwd):
|
||||
- `docs/sheets_export/BatterCalcs.csv`
|
||||
- `docs/sheets_export/PitcherCalcs.csv`
|
||||
|
||||
## Rationale
|
||||
|
||||
The Rust rewrite is being developed on a separate branch (`feat/rust-rewrite`) and needs its own DB so development and testing don't interfere with the production Python app data.
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 75cf8b48-8e9a-467b-9552-fb44d978a9ae
|
||||
type: BUILDS_ON
|
||||
from_id: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
from_title: "Agent swarm wave parallelism for Rust implementation with code review pass"
|
||||
to_id: 99f4462b-91eb-4243-99cf-7a74a3afadbf
|
||||
to_title: "Agent Swarm Orchestrator: architecture decisions and lessons learned"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T04:58:36.352521+00:00"
|
||||
updated: "2026-02-28T04:58:36.352521+00:00"
|
||||
---
|
||||
|
||||
Wave parallelism pattern is a specific application of the general agent swarm orchestrator approach
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 08588ede-b8fa-4b19-9c7e-b513808fa2e7
|
||||
type: CAUSES
|
||||
from_id: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
from_title: "Agent swarm wave parallelism for Rust implementation with code review pass"
|
||||
to_id: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
to_title: "Rust: reqwest response.json() yields reqwest::Error, not serde_json::Error"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T04:58:33.677394+00:00"
|
||||
updated: "2026-02-28T04:58:33.677394+00:00"
|
||||
---
|
||||
|
||||
Code review during the swarm session discovered this reqwest error type bug
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 235a68a1-bb13-43e0-9784-4b8561f7685a
|
||||
type: CAUSES
|
||||
from_id: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
from_title: "Agent swarm wave parallelism for Rust implementation with code review pass"
|
||||
to_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
to_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T04:58:32.030375+00:00"
|
||||
updated: "2026-02-28T04:58:32.030375+00:00"
|
||||
---
|
||||
|
||||
Swarm wave approach was how Phase 2 was implemented and reviewed
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 391f6718-4f2f-49d0-acb8-659b04ed8c51
|
||||
type: RELATED_TO
|
||||
from_id: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
from_title: "Agent swarm wave parallelism for Rust implementation with code review pass"
|
||||
to_id: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
to_title: "Agent swarm workflow for parallel Rust implementation tasks"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T04:58:38.887275+00:00"
|
||||
updated: "2026-02-28T04:58:38.887275+00:00"
|
||||
---
|
||||
|
||||
Both document agent swarm patterns for Rust implementation; this memory adds code review learnings
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: d5c4c47f-9b6c-4016-ab15-42c6bbfe5f25
|
||||
type: BUILDS_ON
|
||||
from_id: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
from_title: "Agent swarm workflow for parallel Rust implementation tasks"
|
||||
to_id: 99f4462b-91eb-4243-99cf-7a74a3afadbf
|
||||
to_title: "Agent Swarm Orchestrator: architecture decisions and lessons learned"
|
||||
strength: 0.7
|
||||
created: "2026-02-27T01:19:10.022871+00:00"
|
||||
updated: "2026-02-27T01:19:10.022871+00:00"
|
||||
---
|
||||
|
||||
Swarm workflow for Rust tasks builds on the orchestrator architecture, adding file-contention batching pattern
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 129677be-d2fe-45f2-a69c-b1340256d48c
|
||||
type: BUILDS_ON
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: 99f4462b-91eb-4243-99cf-7a74a3afadbf
|
||||
to_title: "Agent Swarm Orchestrator: architecture decisions and lessons learned"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T05:06:29.584084+00:00"
|
||||
updated: "2026-02-28T05:06:29.584084+00:00"
|
||||
---
|
||||
|
||||
Playbook is a concrete operational refinement of the general swarm orchestrator architecture lessons
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 91e7a65f-ba4f-4533-b9b6-b9d732762490
|
||||
type: BUILDS_ON
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
to_title: "Agent swarm wave parallelism for Rust implementation with code review pass"
|
||||
strength: 0.95
|
||||
created: "2026-02-28T05:06:27.264870+00:00"
|
||||
updated: "2026-02-28T05:06:27.264870+00:00"
|
||||
---
|
||||
|
||||
Playbook provides the detailed operational how-to for the wave parallelism pattern documented in this solution
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 173a8645-ab54-4247-822b-9fb9e2ca23fd
|
||||
type: BUILDS_ON
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
to_title: "Agent swarm workflow for parallel Rust implementation tasks"
|
||||
strength: 0.85
|
||||
created: "2026-02-28T05:06:34.191031+00:00"
|
||||
updated: "2026-02-28T05:06:34.191031+00:00"
|
||||
---
|
||||
|
||||
Playbook is an operational refinement of the swarm workflow, adding pane management and review patterns
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 10efe7b8-fe41-4e80-8733-e65add502655
|
||||
type: FOLLOWS
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
to_title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T05:06:41.138617+00:00"
|
||||
updated: "2026-02-28T05:06:41.138617+00:00"
|
||||
---
|
||||
|
||||
Phase 1 foundation came before Phase 2 where this playbook was applied
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: c32c4588-17b5-4f00-8d59-37bf89c6f6be
|
||||
type: FOLLOWS
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
to_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T05:06:31.878711+00:00"
|
||||
updated: "2026-02-28T05:06:31.878711+00:00"
|
||||
---
|
||||
|
||||
Playbook documents the operational process used to complete Phase 2 of the Rust rewrite
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 67fc682d-2b46-43c8-b950-bd80147e0056
|
||||
type: RELATED_TO
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
to_title: "Rust: reqwest response.json() yields reqwest::Error, not serde_json::Error"
|
||||
strength: 0.7
|
||||
created: "2026-02-28T05:06:39.175845+00:00"
|
||||
updated: "2026-02-28T05:06:39.175845+00:00"
|
||||
---
|
||||
|
||||
This bug was caught by the code review step documented in the playbook
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 600e028b-6ee2-4413-b35c-220d210fb8fd
|
||||
type: REQUIRES
|
||||
from_id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
from_title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
to_id: 4dfc5003-44f8-4520-8cfc-dc6d6ef9a65f
|
||||
to_title: "Claude Code Agent Teams enabled in ~/.claude/settings.json with tmux controls"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T05:06:36.910547+00:00"
|
||||
updated: "2026-02-28T05:06:36.910547+00:00"
|
||||
---
|
||||
|
||||
Agent Teams must be enabled in settings.json with tmux controls for this playbook to work
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 8b24bed4-38a2-4a70-8b5e-de2782c897e0
|
||||
type: RELATED_TO
|
||||
from_id: 1768d9ab-0c21-4ec3-bb04-bd70366f6240
|
||||
from_title: "File-based logging for Rust TUI apps using tracing-appender"
|
||||
to_id: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
to_title: "SBA Scout Python-to-Rust TUI migration: recommended stack and approach"
|
||||
strength: 0.7
|
||||
created: "2026-02-28T16:53:58.777098+00:00"
|
||||
updated: "2026-02-28T16:53:58.777098+00:00"
|
||||
---
|
||||
|
||||
File logging is a ratatui-specific concern identified in the migration research
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: d07fb339-8eb5-40c8-b63c-fcce499f0fc3
|
||||
type: RELATED_TO
|
||||
from_id: 1768d9ab-0c21-4ec3-bb04-bd70366f6240
|
||||
from_title: "File-based logging for Rust TUI apps using tracing-appender"
|
||||
to_id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
to_title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T16:53:38.490071+00:00"
|
||||
updated: "2026-02-28T16:53:38.490071+00:00"
|
||||
---
|
||||
|
||||
File-based logging is required by the ratatui TUI to avoid display corruption
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: bd644f41-70ec-46b5-bde9-ab32e800315e
|
||||
type: RELATED_TO
|
||||
from_id: 0df0e075-ae86-4208-b08d-a02bb5fa2278
|
||||
from_title: "Fix: Dashboard didn't refresh after sync — re-mount on SyncComplete"
|
||||
to_id: 6d3627c4-5aa1-47f0-a85f-34fe3ea685ac
|
||||
to_title: "Fix: Dashboard position coverage only counted pos_1, not all positions"
|
||||
strength: 0.75
|
||||
created: "2026-02-28T18:10:06.851656+00:00"
|
||||
updated: "2026-02-28T18:10:06.851656+00:00"
|
||||
---
|
||||
|
||||
Both are dashboard fixes in the same session
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 03a7fade-b537-4461-b7bc-91193bb2f304
|
||||
type: FOLLOWS
|
||||
from_id: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
from_title: "Fix: Rust sync excluded IL/MiL teams due to active_only=true"
|
||||
to_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
to_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
strength: 0.85
|
||||
created: "2026-02-28T18:10:11.310671+00:00"
|
||||
updated: "2026-02-28T18:10:11.310671+00:00"
|
||||
---
|
||||
|
||||
Sync bug fix follows Phase 2 sync implementation
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 38e55a1d-2f56-428b-8160-f01f98c6e113
|
||||
type: RELATED_TO
|
||||
from_id: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
from_title: "Fix: Rust sync excluded IL/MiL teams due to active_only=true"
|
||||
to_id: 0df0e075-ae86-4208-b08d-a02bb5fa2278
|
||||
to_title: "Fix: Dashboard didn't refresh after sync — re-mount on SyncComplete"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T18:10:00.107772+00:00"
|
||||
updated: "2026-02-28T18:10:00.107772+00:00"
|
||||
---
|
||||
|
||||
Both are fixes from the same sync/dashboard session — sync correctness feeds into dashboard refresh
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 626fd39b-2fbf-42cc-8131-15e1bc71f492
|
||||
type: RELATED_TO
|
||||
from_id: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
from_title: "Fix: Rust sync excluded IL/MiL teams due to active_only=true"
|
||||
to_id: 6d3627c4-5aa1-47f0-a85f-34fe3ea685ac
|
||||
to_title: "Fix: Dashboard position coverage only counted pos_1, not all positions"
|
||||
strength: 0.7
|
||||
created: "2026-02-28T18:10:02.521468+00:00"
|
||||
updated: "2026-02-28T18:10:02.521468+00:00"
|
||||
---
|
||||
|
||||
Both are dashboard correctness fixes — sync populating correct teams, dashboard displaying correct position coverage
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: e740a946-4100-4771-8449-61ab13896587
|
||||
type: RELATED_TO
|
||||
from_id: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
from_title: "Fix: SBA API Discord snowflake IDs returned as JSON strings not i64"
|
||||
to_id: d5b6584e-ae9d-4462-aeb0-eac103156dfc
|
||||
to_title: "Fix: SBA API transaction move_id is a string not i64"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T16:53:47.424726+00:00"
|
||||
updated: "2026-02-28T16:53:47.424726+00:00"
|
||||
---
|
||||
|
||||
Both are API type deserialization fixes for sba-scout — strings where i64 expected
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 28a2471d-a080-4344-ab1e-5413df9e072c
|
||||
type: RELATED_TO
|
||||
from_id: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
from_title: "Fix: SBA API Discord snowflake IDs returned as JSON strings not i64"
|
||||
to_id: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
to_title: "Rust: reqwest response.json() yields reqwest::Error, not serde_json::Error"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T16:53:52.215098+00:00"
|
||||
updated: "2026-02-28T16:53:52.215098+00:00"
|
||||
---
|
||||
|
||||
Both are Rust serde/API type mismatch fixes for the sba-scout API client
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 5df40dff-4569-4471-96e7-fe1234d93b36
|
||||
type: RELATED_TO
|
||||
from_id: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
from_title: "Fix: SBA API Discord snowflake IDs returned as JSON strings not i64"
|
||||
to_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
to_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T16:53:40.710570+00:00"
|
||||
updated: "2026-02-28T16:53:40.710570+00:00"
|
||||
---
|
||||
|
||||
Discord snowflake fix is part of the Phase 2 API client work
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 5fb91cf0-1aa3-4e71-af81-29c1e43730a9
|
||||
type: RELATED_TO
|
||||
from_id: d5b6584e-ae9d-4462-aeb0-eac103156dfc
|
||||
from_title: "Fix: SBA API transaction move_id is a string not i64"
|
||||
to_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
to_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T16:53:43.054882+00:00"
|
||||
updated: "2026-02-28T16:53:43.054882+00:00"
|
||||
---
|
||||
|
||||
Transaction move_id string fix is part of Phase 2 API type work
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 6f4bc010-3d87-484c-b762-e700036a6b1f
|
||||
type: RELATED_TO
|
||||
from_id: 49a8001d-b3b9-4a29-911a-956db4b37f21
|
||||
from_title: "Fix: SQLite PRAGMA foreign_keys is per-connection, not per-pool"
|
||||
to_id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
to_title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
strength: 0.7
|
||||
created: "2026-02-28T16:54:00.365432+00:00"
|
||||
updated: "2026-02-28T16:54:00.365432+00:00"
|
||||
---
|
||||
|
||||
SQLite FK fix needed for Phase 4 to load transaction data without FK violations
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 38d8bd6e-af74-4d93-9c35-709865f12f2f
|
||||
type: RELATED_TO
|
||||
from_id: 49a8001d-b3b9-4a29-911a-956db4b37f21
|
||||
from_title: "Fix: SQLite PRAGMA foreign_keys is per-connection, not per-pool"
|
||||
to_id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
to_title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T16:53:45.555855+00:00"
|
||||
updated: "2026-02-28T16:53:45.555855+00:00"
|
||||
---
|
||||
|
||||
SQLite PRAGMA per-connection fix relates to Phase 1 foundation DB setup
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 594e81c0-2c76-4412-8513-157d7daa92e3
|
||||
type: RELATED_TO
|
||||
from_id: ad48fe50-12a6-4c65-a49c-3a691d75e03f
|
||||
from_title: "Rust CSV importer integration tested — matches Python DB exactly"
|
||||
to_id: 71261e95-805e-44a0-8ee2-4a0f683dbc1f
|
||||
to_title: "SBA Scout Rust: two separate databases for Rust vs Python apps"
|
||||
strength: 0.85
|
||||
created: "2026-02-28T18:10:05.594987+00:00"
|
||||
updated: "2026-02-28T18:10:05.594987+00:00"
|
||||
---
|
||||
|
||||
Integration test validates the architecture decision to use separate Rust DB
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 1a8007be-890d-4ca2-9c8e-d9bd35c9cb79
|
||||
type: RELATED_TO
|
||||
from_id: baa10a3d-8ec9-4a5b-bb1c-1c80f265473f
|
||||
from_title: "Rust/Cargo installation and fish shell PATH setup on Cal's workstation"
|
||||
to_id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
to_title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
strength: 0.6
|
||||
created: "2026-02-28T16:53:55.359039+00:00"
|
||||
updated: "2026-02-28T16:53:55.359039+00:00"
|
||||
---
|
||||
|
||||
Rust/Cargo workstation setup enables building the sba-scout TUI project
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 0dfd7245-6d94-4a78-84a8-dae22a15fbb1
|
||||
type: FOLLOWS
|
||||
from_id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
from_title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
to_id: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
to_title: "SBA Scout Python-to-Rust TUI migration: recommended stack and approach"
|
||||
strength: 0.8
|
||||
created: "2026-02-28T16:53:35.985579+00:00"
|
||||
updated: "2026-02-28T16:53:35.985579+00:00"
|
||||
---
|
||||
|
||||
Phase 4 implements the ratatui TUI approach decided in migration research
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 915d9199-dab1-401f-81ec-34de8e1d1eb8
|
||||
type: FOLLOWS
|
||||
from_id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
from_title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
to_id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
to_title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T16:53:33.583518+00:00"
|
||||
updated: "2026-02-28T16:53:33.583518+00:00"
|
||||
---
|
||||
|
||||
Phase 4 TUI builds on Phase 1 foundation (DB schema, config)
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 0868f506-7c16-49a6-8d1c-0ced9d74a9cc
|
||||
type: FOLLOWS
|
||||
from_id: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
from_title: "SBA Scout Rust Phase 4: Async TUI with Dashboard and Gameday screens"
|
||||
to_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
to_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T16:53:31.236733+00:00"
|
||||
updated: "2026-02-28T16:53:31.236733+00:00"
|
||||
---
|
||||
|
||||
Phase 4 TUI follows Phase 2 API client implementation
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 92d0e814-2cc0-4622-913c-8b92ad3f280d
|
||||
type: REQUIRES
|
||||
from_id: c7aab060-25b8-4128-a661-eefad9dc4674
|
||||
from_title: "SBA Scout Rust Phase 6: stat weights configurable via TOML settings"
|
||||
to_id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
to_title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
strength: 0.8
|
||||
created: "2026-02-27T01:19:08.017996+00:00"
|
||||
updated: "2026-02-27T01:19:08.017996+00:00"
|
||||
---
|
||||
|
||||
Phase 6 configurable weights requires Phase 1 foundation (config system, settings.toml, figment pipeline)
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 5cde624d-cbf0-456b-aa87-076e7e999dde
|
||||
type: BUILDS_ON
|
||||
from_id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
from_title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
to_id: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
to_title: "SBA Scout Python-to-Rust TUI migration: recommended stack and approach"
|
||||
strength: 0.9
|
||||
created: "2026-02-27T01:19:05.955043+00:00"
|
||||
updated: "2026-02-27T01:19:05.955043+00:00"
|
||||
---
|
||||
|
||||
Phase 1 implementation builds on the original migration research and recommended stack decision
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: b8e47bac-8b05-4e2c-b0a0-bd7683ced31f
|
||||
type: FOLLOWS
|
||||
from_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
from_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
to_id: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
to_title: "SBA Scout Python-to-Rust TUI migration: recommended stack and approach"
|
||||
strength: 0.7
|
||||
created: "2026-02-28T04:58:41.332752+00:00"
|
||||
updated: "2026-02-28T04:58:41.332752+00:00"
|
||||
---
|
||||
|
||||
Phase 2 is part of the migration path described in the stack/approach decision
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: 6dc75271-96a2-43f4-ad96-cfc26ce126c1
|
||||
type: FOLLOWS
|
||||
from_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
from_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
to_id: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
to_title: "SBA Scout Rust rewrite Phase 1 complete — foundation layer implemented"
|
||||
strength: 1.0
|
||||
created: "2026-02-28T04:58:26.882830+00:00"
|
||||
updated: "2026-02-28T04:58:26.882830+00:00"
|
||||
---
|
||||
|
||||
Phase 2 builds directly on Phase 1 foundation (DB schema, config)
|
||||
@ -1,13 +0,0 @@
|
||||
---
|
||||
id: f57f63b8-1a05-4645-a320-4b045569ff55
|
||||
type: RELATED_TO
|
||||
from_id: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
from_title: "SBA Scout Rust rewrite Phase 2 complete — API client, sync, and CSV importers"
|
||||
to_id: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
to_title: "Rust: reqwest response.json() yields reqwest::Error, not serde_json::Error"
|
||||
strength: 0.9
|
||||
created: "2026-02-28T04:58:29.508900+00:00"
|
||||
updated: "2026-02-28T04:58:29.508900+00:00"
|
||||
---
|
||||
|
||||
Phase 2 API client uses the reqwest fix pattern (text + serde_json::from_str)
|
||||
@ -1,46 +0,0 @@
|
||||
---
|
||||
id: 0df0e075-ae86-4208-b08d-a02bb5fa2278
|
||||
type: fix
|
||||
title: "Fix: Dashboard didn't refresh after sync — re-mount on SyncComplete"
|
||||
tags: [sba-scout, rust, dashboard, ux, sync, tui]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T18:09:29.595660+00:00"
|
||||
updated: "2026-02-28T18:10:06.851656+00:00"
|
||||
relations:
|
||||
- target: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 38e55a1d-2f56-428b-8160-f01f98c6e113
|
||||
- target: 6d3627c4-5aa1-47f0-a85f-34fe3ea685ac
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.75
|
||||
edge_id: bd644f41-70ec-46b5-bde9-ab32e800315e
|
||||
---
|
||||
|
||||
# Fix: Dashboard didn't refresh after sync — re-mount on SyncComplete
|
||||
|
||||
## Problem
|
||||
|
||||
The dashboard's `handle_message` for `SyncComplete` updated the sync status display but did not re-fetch roster, team, or card data. Users had to navigate away and back to see the newly synced data reflected.
|
||||
|
||||
## Fix
|
||||
|
||||
Added a `self.mount(pool, tx)` call after successful sync in the `SyncComplete` handler.
|
||||
|
||||
This required changing the `handle_message` method signature to accept:
|
||||
- `pool: &SqlitePool`
|
||||
- `tx: &mpsc::UnboundedSender<AppMessage>`
|
||||
|
||||
The call site in `app.rs` was updated accordingly.
|
||||
|
||||
## Files Affected
|
||||
|
||||
- `screens/dashboard.rs` — updated `handle_message` signature and added `mount` call
|
||||
- `app.rs` — updated call site to pass `pool` and `tx`
|
||||
|
||||
## Committed
|
||||
|
||||
Part of commit `3e73644`.
|
||||
@ -1,35 +0,0 @@
|
||||
---
|
||||
id: 6d3627c4-5aa1-47f0-a85f-34fe3ea685ac
|
||||
type: fix
|
||||
title: "Fix: Dashboard position coverage only counted pos_1, not all positions"
|
||||
tags: [sba-scout, rust, dashboard, positions, bug-fix]
|
||||
importance: 0.55
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T18:09:34.355896+00:00"
|
||||
updated: "2026-02-28T18:10:06.851656+00:00"
|
||||
relations:
|
||||
- target: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.7
|
||||
edge_id: 626fd39b-2fbf-42cc-8131-15e1bc71f492
|
||||
- target: 0df0e075-ae86-4208-b08d-a02bb5fa2278
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.75
|
||||
edge_id: bd644f41-70ec-46b5-bde9-ab32e800315e
|
||||
---
|
||||
|
||||
# Fix: Dashboard position coverage only counted pos_1, not all positions
|
||||
|
||||
## Problem
|
||||
|
||||
Position coverage calculation in the dashboard only iterated `player.pos_1` for each player, missing multi-position eligibility (e.g. a player with 2B/3B/SS eligibility was only counted in pos_1).
|
||||
|
||||
## Fix
|
||||
|
||||
Changed to use the existing `Player::positions()` helper method (defined in `db/models.rs`) which iterates all 8 position fields (`pos_1` through `pos_8`). Now a player with 2B/3B/SS eligibility is counted once in each eligible position bucket.
|
||||
|
||||
## Committed
|
||||
|
||||
Commit `a033a28`.
|
||||
@ -1,51 +0,0 @@
|
||||
---
|
||||
id: 5c11485a-c808-41b6-8576-a8a388b5be1e
|
||||
type: fix
|
||||
title: "Fix: Rust sync excluded IL/MiL teams due to active_only=true"
|
||||
tags: [sba-scout, rust, sync, bug-fix, api, teams]
|
||||
importance: 0.7
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T18:09:23.796074+00:00"
|
||||
updated: "2026-02-28T18:10:11.310671+00:00"
|
||||
relations:
|
||||
- target: 0df0e075-ae86-4208-b08d-a02bb5fa2278
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 38e55a1d-2f56-428b-8160-f01f98c6e113
|
||||
- target: 6d3627c4-5aa1-47f0-a85f-34fe3ea685ac
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.7
|
||||
edge_id: 626fd39b-2fbf-42cc-8131-15e1bc71f492
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.85
|
||||
edge_id: 03a7fade-b537-4461-b7bc-91193bb2f304
|
||||
---
|
||||
|
||||
# Fix: Rust sync excluded IL/MiL teams due to active_only=true
|
||||
|
||||
## Problem
|
||||
|
||||
The Rust `sync_teams()` function in `api/sync.rs` was calling:
|
||||
|
||||
```rust
|
||||
client.get_teams(Some(season), None, true, false)
|
||||
```
|
||||
|
||||
The `active_only=true` parameter caused the API to exclude IL (e.g. WVIL id=549) and MiL (e.g. WVMiL id=550) teams from the response. The Python sync did not pass `active_only` (defaults to `false`), so it correctly synced all teams.
|
||||
|
||||
## Root Cause
|
||||
|
||||
Mismatch between Rust and Python API call defaults for the `active_only` parameter.
|
||||
|
||||
## Fix
|
||||
|
||||
Changed `active_only` from `true` to `false` in `api/sync.rs`.
|
||||
|
||||
## Notes
|
||||
|
||||
- The `get_all_teams()` DB query in `queries.rs` already filters IL/MiL from the Gameday opponent selector using `WHERE abbrev NOT LIKE '%IL' AND abbrev NOT LIKE '%MiL'`, so syncing them does not pollute the UI.
|
||||
- Committed as part of `3e73644`.
|
||||
@ -1,46 +0,0 @@
|
||||
---
|
||||
id: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
type: fix
|
||||
title: "Fix: SBA API Discord snowflake IDs returned as JSON strings not i64"
|
||||
tags: [sba-scout, rust, api, serde, fix, discord, json]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T16:52:52.173698+00:00"
|
||||
updated: "2026-02-28T16:53:52.215098+00:00"
|
||||
relations:
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 5df40dff-4569-4471-96e7-fe1234d93b36
|
||||
- target: d5b6584e-ae9d-4462-aeb0-eac103156dfc
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: e740a946-4100-4771-8449-61ab13896587
|
||||
- target: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 28a2471d-a080-4344-ab1e-5413df9e072c
|
||||
---
|
||||
|
||||
# Discord Snowflake IDs as JSON Strings
|
||||
|
||||
**Project:** sba-scout (Rust) | **Commit:** `a18c043`
|
||||
|
||||
## Problem
|
||||
|
||||
The SBA league API returns Discord snowflake IDs (`gmid`, `gmid2` fields on teams) as **quoted strings** (e.g. `"258104532423147520"`) to avoid JavaScript 53-bit integer precision loss. Deserializing as `i64` fails with a type error.
|
||||
|
||||
## Fix
|
||||
|
||||
Changed `gm_discord_id` and `gm2_discord_id` from `Option<i64>` to `Option<String>` in `api/types.rs` `TeamData` struct.
|
||||
|
||||
## Why
|
||||
|
||||
JavaScript's `Number` type can only represent integers up to 2^53 - 1 (~9 quadrillion). Discord snowflakes can exceed this, so APIs return them as strings. Rust's `i64` is fine numerically, but the JSON schema says string.
|
||||
|
||||
## Pattern
|
||||
|
||||
When consuming any API that originated from a JavaScript ecosystem (Discord, Twitter, etc.), treat large IDs as `String` types unless the API explicitly documents them as numbers.
|
||||
@ -1,37 +0,0 @@
|
||||
---
|
||||
id: d5b6584e-ae9d-4462-aeb0-eac103156dfc
|
||||
type: fix
|
||||
title: "Fix: SBA API transaction move_id is a string not i64"
|
||||
tags: [sba-scout, rust, api, serde, fix, transactions]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T16:52:56.737424+00:00"
|
||||
updated: "2026-02-28T16:53:47.424726+00:00"
|
||||
relations:
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 5fb91cf0-1aa3-4e71-af81-29c1e43730a9
|
||||
- target: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: e740a946-4100-4771-8449-61ab13896587
|
||||
---
|
||||
|
||||
# Transaction move_id as String
|
||||
|
||||
**Project:** sba-scout (Rust) | **Commit:** `60b397b`
|
||||
|
||||
## Problem
|
||||
|
||||
The SBA league API returns transaction `moveid` as a formatted string like `"Season-013-Week-11-1772073335"`, not an integer. Deserializing as `Option<i64>` panics/errors.
|
||||
|
||||
## Fix
|
||||
|
||||
Changed `move_id` from `Option<i64>` to `Option<String>` in `api/types.rs` `TransactionData` struct.
|
||||
|
||||
## Pattern
|
||||
|
||||
Don't assume numeric-looking field names in an API are actually integers. Inspect real API responses before choosing Rust types. Transaction/move identifiers often encode semantic information as composite strings.
|
||||
@ -1,49 +0,0 @@
|
||||
---
|
||||
id: 49a8001d-b3b9-4a29-911a-956db4b37f21
|
||||
type: fix
|
||||
title: "Fix: SQLite PRAGMA foreign_keys is per-connection, not per-pool"
|
||||
tags: [sba-scout, rust, sqlx, sqlite, fix, pragma, connection-pool]
|
||||
importance: 0.7
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T16:53:04.445263+00:00"
|
||||
updated: "2026-02-28T16:54:00.365432+00:00"
|
||||
relations:
|
||||
- target: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 38d8bd6e-af74-4d93-9c35-709865f12f2f
|
||||
- target: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.7
|
||||
edge_id: 6f4bc010-3d87-484c-b762-e700036a6b1f
|
||||
---
|
||||
|
||||
# SQLite PRAGMA Scope with sqlx Connection Pools
|
||||
|
||||
**Project:** sba-scout (Rust)
|
||||
|
||||
## Problem
|
||||
|
||||
When using sqlx connection pools, `PRAGMA` statements only affect the specific connection they run on. Running `PRAGMA foreign_keys = OFF` via `pool.execute()` may use a different connection than subsequent queries — so FK enforcement remains on for those queries.
|
||||
|
||||
## Fix
|
||||
|
||||
Use `SqliteConnectOptions::foreign_keys(false)` to apply the setting to **every** connection the pool creates, not just whichever one happens to handle the PRAGMA execute call.
|
||||
|
||||
```rust
|
||||
let opts = SqliteConnectOptions::from_str(&db_url)?
|
||||
.foreign_keys(false)
|
||||
.create_if_missing(true);
|
||||
|
||||
let pool = SqlitePool::connect_with(opts).await?;
|
||||
```
|
||||
|
||||
## Context
|
||||
|
||||
For sba-scout, FK enforcement was disabled entirely because transactions reference players/teams that may not exist locally (data arrives out of order from the API).
|
||||
|
||||
## General Rule
|
||||
|
||||
Any SQLite session-level setting (PRAGMA) must be applied at the connection options level when using a pool, not via a one-off `execute()` call.
|
||||
@ -6,28 +6,7 @@ tags: [rust, reqwest, serde, error-handling, serde_json, api]
|
||||
importance: 0.5
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T04:58:15.771467+00:00"
|
||||
updated: "2026-02-28T16:53:52.215098+00:00"
|
||||
relations:
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: f57f63b8-1a05-4645-a320-4b045569ff55
|
||||
- target: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
type: CAUSES
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: 08588ede-b8fa-4b19-9c7e-b513808fa2e7
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.7
|
||||
edge_id: 67fc682d-2b46-43c8-b950-bd80147e0056
|
||||
- target: 23121a41-790a-4bf3-9a4b-39f299bc4015
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 28a2471d-a080-4344-ab1e-5413df9e072c
|
||||
updated: "2026-03-01T22:02:57.289593+00:00"
|
||||
---
|
||||
|
||||
# Fix: reqwest JSON Error Type Mismatch
|
||||
@ -63,3 +42,7 @@ This lets callers distinguish **network errors** (connection dropped, timeout) f
|
||||
## Context
|
||||
|
||||
Caught during code review of `api/client.rs` in SBA Scout Rust rewrite Phase 2.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -1,116 +0,0 @@
|
||||
---
|
||||
id: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: procedure
|
||||
title: "Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review"
|
||||
tags: [claude-code, swarm, agent-teams, orchestrator, code-review, procedure, lessons-learned, rust, sba-scout]
|
||||
importance: 0.8
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T05:06:14.591287+00:00"
|
||||
updated: "2026-02-28T05:06:41.138617+00:00"
|
||||
relations:
|
||||
- target: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
type: BUILDS_ON
|
||||
direction: outgoing
|
||||
strength: 0.95
|
||||
edge_id: 91e7a65f-ba4f-4533-b9b6-b9d732762490
|
||||
- target: 99f4462b-91eb-4243-99cf-7a74a3afadbf
|
||||
type: BUILDS_ON
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: 129677be-d2fe-45f2-a69c-b1340256d48c
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: c32c4588-17b5-4f00-8d59-37bf89c6f6be
|
||||
- target: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
type: BUILDS_ON
|
||||
direction: outgoing
|
||||
strength: 0.85
|
||||
edge_id: 173a8645-ab54-4247-822b-9fb9e2ca23fd
|
||||
- target: 4dfc5003-44f8-4520-8cfc-dc6d6ef9a65f
|
||||
type: REQUIRES
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 600e028b-6ee2-4413-b35c-220d210fb8fd
|
||||
- target: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.7
|
||||
edge_id: 67fc682d-2b46-43c8-b950-bd80147e0056
|
||||
- target: c9add129-283a-445a-8dff-4525ec7fa9b6
|
||||
type: FOLLOWS
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 10efe7b8-fe41-4e80-8733-e65add502655
|
||||
---
|
||||
|
||||
# Agent Team Operational Playbook: Wave-Based Parallel Implementation with Code Review
|
||||
|
||||
Detailed operational lessons from running a 7-task Rust implementation with agent teams (Phase 2 of SBA Scout rewrite). This captures what worked, what didn't, and specific patterns to follow.
|
||||
|
||||
## Preconditions
|
||||
- Detailed task specs written up with file paths and reference code
|
||||
- Dependency graph between tasks already mapped
|
||||
- Enough tmux pane slots for parallel agents (check before launching)
|
||||
|
||||
## Postconditions
|
||||
- All code compiles (`cargo check` or equivalent passes)
|
||||
- Tests pass
|
||||
- All review findings addressed
|
||||
- Team cleaned up (TeamDelete)
|
||||
|
||||
## Team Setup
|
||||
|
||||
- Use `TeamCreate` to create the team, then `TaskCreate` for all tasks upfront with full dependency chains (`TaskUpdate addBlockedBy`)
|
||||
- **Task descriptions must be extremely detailed**: include exact file paths, column mappings, reference files to read, expected function signatures
|
||||
- Agents that got detailed specs produced compiling code on first try with zero clarification needed
|
||||
- Use `isolation: "worktree"` for all coders so they work on independent copies
|
||||
|
||||
## Wave Execution Pattern
|
||||
|
||||
1. Map the dependency graph first, identify which tasks can run in parallel
|
||||
2. Launch parallel coders for independent tasks (Wave 1: e.g. 3 agents on independent files)
|
||||
3. After each wave completes: verify compilation on main worktree (`cargo check`), then launch next wave
|
||||
4. Worktree changes auto-merge back to the working directory when agents complete
|
||||
|
||||
## Pane Limit Management (CRITICAL)
|
||||
|
||||
- Hit "no space for new pane" error when trying to launch an agent with 6 idle agents still alive
|
||||
- **Solution: Send `shutdown_request` to ALL completed agents IMMEDIATELY after their task is done — do not let them idle**
|
||||
- Do not wait for batch shutdown — shut down each agent as soon as you confirm their task is complete
|
||||
- The idle notification spam from completed agents is noise — ignore it, just send `shutdown_request`
|
||||
|
||||
## Code Review Pattern That Worked
|
||||
|
||||
- Launch reviewer agents (`swarm-reviewer` type) after each wave or at the end
|
||||
- Provide explicit review checklists in the prompt: list every field mapping, every edge case, every cross-reference file
|
||||
- The reviewer caught 2 real bugs that would have caused runtime issues in the Phase 2 run:
|
||||
1. Missing `#[serde(default)]` on 8 `TeamData` fields — would cause deserialization panics if API omits optional fields
|
||||
2. Dead `ApiError::Parse` variant — `response.json()` returns `reqwest::Error` not `serde_json::Error`, so the `Parse` variant was unreachable
|
||||
- Also caught: `import_all_cards` hard-failing on first missing CSV (should try both card types independently)
|
||||
- **Apply fixes yourself (team lead) rather than sending back to coders** — faster for small mechanical fixes
|
||||
|
||||
## Full Step-by-Step
|
||||
|
||||
1. Create team + all tasks with dependencies
|
||||
2. Map dependency graph into waves
|
||||
3. Launch Wave N coders in parallel (worktree isolation)
|
||||
4. Wait for completion + verify compilation
|
||||
5. Shut down completed agents immediately (do not batch)
|
||||
6. Launch reviewer for completed wave's files
|
||||
7. Apply review fixes directly
|
||||
8. Launch Wave N+1
|
||||
9. Repeat steps 3–8 until all waves done
|
||||
10. Final comprehensive review across all files
|
||||
11. Clean up team (TeamDelete)
|
||||
|
||||
## What to Improve Next Time
|
||||
|
||||
- Shut down agents between waves, not in batches at the end
|
||||
- Could run final review in parallel with later-wave coders if the review only covers earlier-wave files
|
||||
- For tasks that produce very similar code (e.g. batter importer vs pitcher importer), consider having one coder do both sequentially instead of two coders — avoids code style divergence
|
||||
- Agent model: sonnet for both coders and reviewers (cost-effective, reliable for implementation tasks)
|
||||
|
||||
## Context
|
||||
Validated on: SBA Scout Rust rewrite Phase 2 (7 tasks: API client, sync orchestrator, batter importer, pitcher importer, team importer, transaction importer, query layer)
|
||||
@ -6,23 +6,7 @@ tags: [orchestrator, swarm, claude-code, agents, skills]
|
||||
importance: 0.9
|
||||
confidence: 0.8
|
||||
created: "2026-02-18T22:56:43.745740+00:00"
|
||||
updated: "2026-02-28T05:06:29.584084+00:00"
|
||||
relations:
|
||||
- target: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
type: BUILDS_ON
|
||||
direction: incoming
|
||||
strength: 0.7
|
||||
edge_id: d5c4c47f-9b6c-4016-ab15-42c6bbfe5f25
|
||||
- target: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
type: BUILDS_ON
|
||||
direction: incoming
|
||||
strength: 0.8
|
||||
edge_id: 75cf8b48-8e9a-467b-9552-fb44d978a9ae
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: BUILDS_ON
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: 129677be-d2fe-45f2-a69c-b1340256d48c
|
||||
updated: "2026-03-01T22:02:57.280383+00:00"
|
||||
---
|
||||
|
||||
## Agent Swarm Orchestrator System
|
||||
@ -60,3 +44,6 @@ Built a lightweight orchestration system using Claude Code native primitives. It
|
||||
- Orchestrator sometimes edits files itself for cosmetic fixes despite instructions not to
|
||||
- No PROJECT_PLAN.json integration yet (planned)
|
||||
- No resume/checkpoint capability if orchestrator context fills up
|
||||
|
||||
|
||||
|
||||
|
||||
@ -1,60 +0,0 @@
|
||||
---
|
||||
id: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
type: solution
|
||||
title: "Agent swarm wave parallelism for Rust implementation with code review pass"
|
||||
tags: [claude-code, swarm, orchestrator, code-review, rust, sba-scout, workflow]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T04:58:09.031652+00:00"
|
||||
updated: "2026-02-28T05:06:27.264870+00:00"
|
||||
relations:
|
||||
- target: 4dc83eed-b0b1-4924-b82e-faf352426785
|
||||
type: CAUSES
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 235a68a1-bb13-43e0-9784-4b8561f7685a
|
||||
- target: 27a1f728-ec90-469c-a6ab-5644d333322f
|
||||
type: CAUSES
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: 08588ede-b8fa-4b19-9c7e-b513808fa2e7
|
||||
- target: 99f4462b-91eb-4243-99cf-7a74a3afadbf
|
||||
type: BUILDS_ON
|
||||
direction: outgoing
|
||||
strength: 0.8
|
||||
edge_id: 75cf8b48-8e9a-467b-9552-fb44d978a9ae
|
||||
- target: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: 391f6718-4f2f-49d0-acb8-659b04ed8c51
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: BUILDS_ON
|
||||
direction: incoming
|
||||
strength: 0.95
|
||||
edge_id: 91e7a65f-ba4f-4533-b9b6-b9d732762490
|
||||
---
|
||||
|
||||
# Agent Swarm Wave Pattern for Rust Implementation
|
||||
|
||||
Used TeamCreate + Agent worktrees for parallel Rust implementation across 3 waves based on dependency graph.
|
||||
|
||||
## What Worked
|
||||
|
||||
- **Wave parallelism** works well when tasks map to separate files (`types.rs`, `client.rs`, `importer.rs`, `sync.rs`) — no merge conflicts, each agent owns its file
|
||||
- **Full task descriptions** with column mappings and reference file paths let coders work autonomously with zero clarification needed
|
||||
- **All 7 coders produced compiling code on first try** — the thorough task specs paid off
|
||||
|
||||
## Problems Encountered
|
||||
|
||||
- **Pane limit hit**: Got "no space for new pane" error when 6 idle agents from earlier waves were still alive. Shut down idle agents promptly between waves to avoid this.
|
||||
|
||||
## Code Review Caught Real Bugs
|
||||
|
||||
1. **Missing `#[serde(default)]` on 8 TeamData fields** — would cause runtime deserialization panics when API returns objects without those optional fields
|
||||
2. **Dead `ApiError::Parse` variant** — `response.json()` returns `reqwest::Error` not `serde_json::Error`, making the Parse variant unreachable. Fix: use `response.text()` + `serde_json::from_str()`
|
||||
3. **`import_all_cards` hard-failing** on first missing CSV — changed to resilient independent tries for each CSV
|
||||
|
||||
## Recommendation
|
||||
|
||||
Always run a code review agent after implementation waves, especially for error handling and serde derives. The review ROI was high — caught 3 bugs that would have been runtime failures.
|
||||
@ -1,68 +0,0 @@
|
||||
---
|
||||
id: 1768d9ab-0c21-4ec3-bb04-bd70366f6240
|
||||
type: solution
|
||||
title: "File-based logging for Rust TUI apps using tracing-appender"
|
||||
tags: [sba-scout, rust, tracing, logging, tui, ratatui, solution]
|
||||
importance: 0.6
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T16:53:12.444250+00:00"
|
||||
updated: "2026-02-28T16:53:58.777098+00:00"
|
||||
relations:
|
||||
- target: bc4abc6e-57c1-4d6c-b414-213c1367be9b
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.9
|
||||
edge_id: d07fb339-8eb5-40c8-b63c-fcce499f0fc3
|
||||
- target: 2cf3058c-85f4-481a-bbe7-17ebb9b9e908
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.7
|
||||
edge_id: 8b24bed4-38a2-4a70-8b5e-de2782c897e0
|
||||
---
|
||||
|
||||
# File Logging for Rust TUI Apps
|
||||
|
||||
**Project:** sba-scout (Rust) | **Commit:** `bf7c3f8`
|
||||
|
||||
## Problem
|
||||
|
||||
Writing to stdout/stderr corrupts ratatui TUI display. Any tracing output needs to go to a file instead.
|
||||
|
||||
## Solution
|
||||
|
||||
Use `tracing-appender` with `rolling::never()` for a fixed log file path.
|
||||
|
||||
### Dependencies
|
||||
|
||||
```toml
|
||||
tracing = "0.1"
|
||||
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
|
||||
tracing-appender = "0.2"
|
||||
```
|
||||
|
||||
### Setup
|
||||
|
||||
```rust
|
||||
use tracing_appender::rolling;
|
||||
use tracing_subscriber::EnvFilter;
|
||||
|
||||
let file_appender = rolling::never("data", "sba-scout.log");
|
||||
let (non_blocking, _guard) = tracing_appender::non_blocking(file_appender);
|
||||
|
||||
tracing_subscriber::fmt()
|
||||
.with_env_filter(EnvFilter::from_default_env())
|
||||
.with_writer(non_blocking)
|
||||
.init();
|
||||
|
||||
// _guard must stay alive for the duration of the app!
|
||||
```
|
||||
|
||||
### Usage
|
||||
|
||||
- Set `RUST_LOG=debug` (or `info`, `error`, etc.) for verbose output
|
||||
- Log is written to `data/sba-scout.log`
|
||||
- Add `tracing::error!()` alongside UI notification sends to capture full error context in log
|
||||
|
||||
## Critical
|
||||
|
||||
The `WorkerGuard` returned by `non_blocking()` must be kept alive (stored in a variable that lives for the entire app scope). Dropping it early silently stops log output.
|
||||
@ -1,45 +0,0 @@
|
||||
---
|
||||
id: ad48fe50-12a6-4c65-a49c-3a691d75e03f
|
||||
type: solution
|
||||
title: "Rust CSV importer integration tested — matches Python DB exactly"
|
||||
tags: [sba-scout, rust, importer, csv, testing, integration-test]
|
||||
importance: 0.7
|
||||
confidence: 0.8
|
||||
created: "2026-02-28T18:09:42.807948+00:00"
|
||||
updated: "2026-02-28T18:10:05.594987+00:00"
|
||||
relations:
|
||||
- target: 71261e95-805e-44a0-8ee2-4a0f683dbc1f
|
||||
type: RELATED_TO
|
||||
direction: outgoing
|
||||
strength: 0.85
|
||||
edge_id: 594e81c0-2c76-4412-8513-157d7daa92e3
|
||||
---
|
||||
|
||||
# Rust CSV importer integration tested — matches Python DB exactly
|
||||
|
||||
## Context
|
||||
|
||||
The Rust CSV card importer (`api/importer.rs`) had unit tests for parse helpers but no integration test against real CSV data. The Rust DB previously had 0 cards because the importer had never been run against actual files.
|
||||
|
||||
## Test Run
|
||||
|
||||
1. Copied `BatterCalcs.csv` and `PitcherCalcs.csv` to `rust/docs/sheets_export/`
|
||||
2. Ran `import_all_cards()` against the Rust DB (`rust/data/sba_scout.db`)
|
||||
|
||||
## Results
|
||||
|
||||
| Type | Cards Imported | Errors |
|
||||
|---------|---------------|--------|
|
||||
| Batter | 490 | 0 |
|
||||
| Pitcher | 502 | 0 |
|
||||
|
||||
Identical to Python DB row counts. Sample values verified (Rutschman batter card, Ben Brown pitcher card).
|
||||
|
||||
## Committed
|
||||
|
||||
CSVs committed to repo at `rust/docs/sheets_export/`.
|
||||
|
||||
## Key Notes
|
||||
|
||||
- Default CSV paths are relative to `rust/` cwd: `docs/sheets_export/BatterCalcs.csv` and `docs/sheets_export/PitcherCalcs.csv`
|
||||
- The Rust app uses `rust/data/sba_scout.db` (separate from Python's `data/sba_scout.db`)
|
||||
@ -1,57 +0,0 @@
|
||||
---
|
||||
id: 3227a923-84c4-4fe3-8574-dbf74d6e8b37
|
||||
type: workflow
|
||||
title: "Agent swarm workflow for parallel Rust implementation tasks"
|
||||
tags: [sba-scout, rust, swarm, claude-code, workflow, parallelism, agent, tmux]
|
||||
importance: 0.5
|
||||
confidence: 0.8
|
||||
created: "2026-02-27T01:18:38.159503+00:00"
|
||||
updated: "2026-02-28T05:06:34.191031+00:00"
|
||||
relations:
|
||||
- target: 99f4462b-91eb-4243-99cf-7a74a3afadbf
|
||||
type: BUILDS_ON
|
||||
direction: outgoing
|
||||
strength: 0.7
|
||||
edge_id: d5c4c47f-9b6c-4016-ab15-42c6bbfe5f25
|
||||
- target: 3ecd877b-de73-4afd-b328-b3ee99f5a1e3
|
||||
type: RELATED_TO
|
||||
direction: incoming
|
||||
strength: 0.9
|
||||
edge_id: 391f6718-4f2f-49d0-acb8-659b04ed8c51
|
||||
- target: 0e484de1-cb92-479c-95ec-06fa9e886c0c
|
||||
type: BUILDS_ON
|
||||
direction: incoming
|
||||
strength: 0.85
|
||||
edge_id: 173a8645-ab54-4247-822b-9fb9e2ca23fd
|
||||
---
|
||||
|
||||
# Agent Swarm Workflow for Parallel Rust Implementation
|
||||
|
||||
## Context
|
||||
Used during SBA Scout Rust rewrite Phase 1 to parallelize implementation across multiple files.
|
||||
|
||||
## Workflow Pattern
|
||||
|
||||
1. **Create team** — spin up tmux-backed swarm with named agents
|
||||
2. **Create tasks with dependencies** — map out which tasks are unblocked vs. blocked
|
||||
3. **Fan out unblocked tasks** to `swarm-coder` agents (bypassPermissions mode)
|
||||
4. **Send completed work to `swarm-reviewer` agents** for code review
|
||||
5. **Fix issues found by reviewers** before proceeding
|
||||
6. **Dispatch newly-unblocked tasks** after dependencies complete
|
||||
|
||||
## Critical Rule: File Contention
|
||||
|
||||
When multiple tasks write to the **same file** (e.g., all query functions going into `queries.rs`), batch them into **one coder agent** to avoid merge conflicts.
|
||||
|
||||
Tasks touching **different files** (e.g., `main.rs` vs `queries.rs` vs `schema.rs`) can safely run in parallel.
|
||||
|
||||
## Agent Configuration
|
||||
- Model: Sonnet (per Cal's preference for sub-agents)
|
||||
- Mode: `bypassPermissions` for coder agents
|
||||
- Reviewer agents: separate agent instances, no bypass needed
|
||||
|
||||
## Outcome
|
||||
Phase 1 completed faster than sequential implementation. Reviewer caught a missing `UNIQUE` constraint on `lineups.name` that was fixed before commit — review step proved valuable.
|
||||
|
||||
## Applicable Projects
|
||||
Any multi-file Rust (or other language) implementation where tasks can be decomposed by file/module ownership.
|
||||
Loading…
Reference in New Issue
Block a user