Commit f946973
feat(release): 0.3.0 — three analyst-grade templates for VC/PE/equities + four infrastructure fixes for deep-research reliability
0.3.0 turns Perplexed into a serious analyst tooling layer for Venture
Capital, Private Equity, and equities-trading workflows. Three new directory
templates produce 6-9K-word cited analyst drafts in a single Perplexity
Deep Research run. Underneath them, four infrastructure fixes turn
deep-research from a brittle "might work" workflow into something you can
put real analyst time behind.
The three new templates: market-map-profile (analyst memo for Known
Category or Thesis-Driven maps), standards-and-specs-profile (open-spec
profiles with five-way authority typing and three-tier adoption framing),
market-category-profile (concept-folder reference card with three
financial-stage tiers — Incumbents / Challengers / Innovators). The four
infrastructure fixes: per-template request-timeout-ms wall-clock override
(yesterday, pressure-relief valve), structural port of per-chunk
idle-timeout discipline from the legacy modal flow into the
directory-template flow (yesterday, structural fix), per-template
max-tokens Perplexity output-budget override (today, fixes silent
clean-truncation when finish_reason=length fires mid-template), and a
strengthened mermaid-discipline partial plus new latex-discipline partial
(today, fixes the 4-of-5 broken-Mermaid rate via paired BAD/GOOD examples
and a six-item pre-emit self-check).
New templates (src/docs/templates/):
- market-map-profile.md — sonar-deep-research, request-timeout-ms 2400000
(40-min ceiling), max-tokens 24000. Anti-incumbent editorial stance.
- standards-and-specs-profile.md — sonar-deep-research, request-timeout-ms 0
(idle-only safety), max-tokens 24000. Five-way authority typing, named
editors, stewardship transitions, named critics.
- market-category-profile.md — sonar-deep-research, request-timeout-ms 0,
max-tokens 24000. Three-tier financial-stage framing, separate Why Now
and What's Happening sections, Industry Coverage sub-grouped into
Market Reports / Industry Articles / Financial News.
Rendering-discipline partials (src/docs/partials/):
- mermaid-discipline.md rewritten — paired BAD/GOOD examples throughout,
the & escape rule, explicit \n vs <br/> ban, six-item self-check
before emit, simplify-rather-than-break ethos. Original ~250 tokens
expanded to ~440.
- latex-discipline.md new — Obsidian MathJax delimiters and \$ escaping
in prose to avoid accidental inline-math spans.
- concept-profile.md wired in {{include: latex-discipline}} alongside the
existing {{include: mermaid-discipline}}, placed immediately after the
"render a mermaid codefence here" instruction so the rules are in scope
at the moment of generation.
Streaming, timeout, and output-budget infrastructure (src/services/
directoryTemplateService.ts):
- streamPerplexityToFile now races each reader.read() against a fresh
per-chunk idle timer (270s deep-research, 90s normal — matches the
legacy modal flow at perplexityService.ts:659). Closes the
"Wall-clock-timeout cuts off long deep-research streams" issue.
- request-timeout-ms cft override is now the optional absolute wall-clock
ceiling (belt-and-suspenders backstop on top of the idle timer);
explicit 0 disables.
- max-tokens cft override added to buildPayload — passes through to
Perplexity's max_tokens parameter; lifts the silent ~8K-token default
ceiling that was clean-truncating thorough drafts via finish_reason:
length.
Documentation (README.md, docs/directory-templates.md):
- README — new top-level section "For Venture Capital, Private Equity, and
Equities-Trading Workflows" with a five-row table mapping each analyst
workflow to the template that produces it. Directory Templates section
updated to seven shipped templates plus the new per-template cft-block
knobs.
- docs/directory-templates.md — new "Per-template max-tokens override"
section with the diagnostic table for distinguishing wall-clock-timeout
truncation (mid-sentence cutoff, no sources footer) from max_tokens
truncation (clean section-end, full sources footer). The diagnostic
vocabulary that did not exist before this release.
Seeding (src/services/templateSeederService.ts):
- Registered all three new templates plus the new latex-discipline partial
so they auto-seed into vaults on first plugin load and appear in
Re-seed runs.
Version bump (manifest.json, package.json, versions.json):
- 0.2.1 to 0.3.0. minAppVersion unchanged at 1.8.10.
Engineering changelog entries (changelog/):
- 2026-05-26_02.md — the structural idle-timeout port.
- 2026-05-27_01.md — the two new templates, max-tokens override, and
rendering-discipline partial work. Includes the diagnostic-led
narrative on the vault-drift bug that caused the 4-of-5 broken-Mermaid
rate.
Release narratives:
- changelog/releases/0.3.0.md — full marketing-quality release narrative
with frontmatter, four-audience cascade, three diagnostic-led stories
(streaming-timeout, max_tokens, rendering-discipline), explicit upgrade
notes including the vault-drift warning, three deferred items for 0.4.x.
- release-notes/0.3.0.md — prose-only release-page body picked up by the
release.yml workflow when the 0.3.0 tag is pushed. Tighter cut of the
same narrative, suited for the GitHub release page.
Context-v stamp:
- context-v/issues/Wall-Clock-Timeout-Cuts-Off-Long-Deep-Research-Streams.md
marked status: resolved, date_resolved 2026-05-26, with the four open
items reorganized into "what landed" (3 of 4) and "deferred follow-ups"
(cross-service audit, settings-pane exposure, deep-research detection
robustness).
Files changed:
- manifest.json, package.json, versions.json
- README.md, docs/directory-templates.md
- src/services/directoryTemplateService.ts
- src/services/templateSeederService.ts
- src/docs/templates/README.md
- src/docs/templates/concept-profile.md
- src/docs/templates/market-map-profile.md
- src/docs/templates/market-category-profile.md (new)
- src/docs/templates/standards-and-specs-profile.md (new)
- src/docs/partials/mermaid-discipline.md
- src/docs/partials/latex-discipline.md (new)
- changelog/2026-05-26_02.md (new)
- changelog/2026-05-27_01.md (new)
- changelog/releases/0.3.0.md (new)
- release-notes/0.3.0.md (new)
- context-v/issues/Wall-Clock-Timeout-Cuts-Off-Long-Deep-Research-Streams.md
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 96df705 commit f946973
19 files changed
Lines changed: 1572 additions & 76 deletions
File tree
- changelog
- releases
- context-v/issues
- docs
- release-notes
- src
- docs
- partials
- templates
- services
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
6 | 20 | | |
7 | 21 | | |
8 | 22 | | |
| |||
50 | 64 | | |
51 | 65 | | |
52 | 66 | | |
| 67 | + | |
53 | 68 | | |
54 | 69 | | |
55 | 70 | | |
| |||
435 | 450 | | |
436 | 451 | | |
437 | 452 | | |
438 | | - | |
439 | | - | |
440 | | - | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
441 | 457 | | |
442 | 458 | | |
443 | 459 | | |
| |||
452 | 468 | | |
453 | 469 | | |
454 | 470 | | |
455 | | - | |
| 471 | + | |
456 | 472 | | |
457 | 473 | | |
458 | 474 | | |
459 | | - | |
| 475 | + | |
460 | 476 | | |
461 | 477 | | |
462 | 478 | | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
463 | 482 | | |
464 | | - | |
| 483 | + | |
465 | 484 | | |
466 | 485 | | |
467 | 486 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
0 commit comments