feat(ansible-example): add @ansible/example package, tests, CI, publish & deploy workflows, docs and changelog
This commit is contained in:
@@ -37,7 +37,7 @@ SVD finds the dominant axes of variation — the directions along which the cham
|
||||
<p>---</p>
|
||||
<h2>Step 2: What Each Motion Is Actually About</h2>
|
||||
<p>Voting patterns tell us <em>who</em> agrees, but not <em>why</em>. For that, I add <strong>text embeddings</strong> — dense vector representations of each motion's content using a language model.</p>
|
||||
<p>I use <strong><code>qwen/qwen3-embedding-4b</code></strong> via OpenRouter — a 4-billion parameter multilingual model that produces 2560-dimensional vectors with strong Dutch-language support. For each motion, I embed the richest text available: full parliamentary body text when we have it (94% of the 28,172 motions after an enrichment pass against the Tweede Kamer API), falling back to the summary description or title otherwise.</p>
|
||||
<p>I use <strong><code>qwen/qwen3-embedding-4b</code></strong> via OpenRouter — a 4-billion parameter multilingual model that produces 2560-dimensional vectors with strong Dutch-language support. For each motion, I embed the richest text available: full parliamentary body text when we have it (94% of the 28,172 motions after an enrichment pass against the Tweede Kamer API), falling back to the summary description or title otherwise. Configuration: prefer OPENROUTER_API_KEY and fall back to OPENAI_API_KEY where appropriate.</p>
|
||||
<p>This lets us do something powerful: find motions that are genuinely similar in <em>topic</em>, not just in voting pattern. Two motions about nitrogen policy from 2020 and 2023 might have very different vote splits (different coalitions, different political moment) but near-identical text embeddings. That's a meaningful connection.</p>
|
||||
<p>---</p>
|
||||
<h2>Step 3: Fused Embeddings — The Best of Both Worlds</h2>
|
||||
@@ -88,7 +88,7 @@ SVD finds the dominant axes of variation — the directions along which the cham
|
||||
<p>motions
|
||||
→ extract_mp_votes.py → mp_votes table (506,336 rows)
|
||||
→ sync_motion_content.py → body_text enrichment (26,447 motions, ~94%)
|
||||
→ text_pipeline.py → embeddings table (28,172 rows, qwen3-embedding-4b via OpenRouter)
|
||||
→ text_pipeline.py → embeddings table (28,172 rows, qwen3-embedding-4b via OpenRouter). Configuration: prefer OPENROUTER_API_KEY with OPENAI_API_KEY as a fallback.
|
||||
→ svd_pipeline.py → svd_vectors table (54,150 rows, 38 windows)</p>
|
||||
<p>svd_vectors + embeddings
|
||||
→ fusion.py → fused_embeddings table (40,522 rows)</p>
|
||||
@@ -116,4 +116,4 @@ python scripts/sync_motion_content.py --db-path data/motions.db</code></pre>
|
||||
<p>The DB grows to ~15 GB for the full dataset including body text. All computation — SVD, fusion, similarity — runs locally on a single machine.</p>
|
||||
<p>Democracy is more legible than it looks.</p>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user