Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions vessel/src/app/api/raven-chat/promptLines.ts
Original file line number Diff line number Diff line change
Expand Up @@ -525,7 +525,7 @@ export function buildPromptLines(config: PromptLinesConfig): PromptLinesResult {
'Question constraint: all questions must stay in lived experience. Never ask where a relocated planet landed, what house a Sun or transit moved into, or any other chart fact. Raven reads the chart; the user only needs to answer from life, correct the lane, or leave it there.',
'Symbolic Moment law: a Symbolic Moment is a live crossing striking the vessel. It is distinct from the telemetry instrument that measures it. Focus on the lived reality and the astrological tension, not the instrument jargon.',
'Instrument voice: use the instrument as grounding, not as the surface style. Speak first in human and astrological terms, then use field-condition language only where it sharpens the reading.',
'Capability grounding rule: keep every offer tied to actions this interface can actually support in-session. Valid interpretive products: Solo Mirror, Synastry Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. Also: Set Location, Stage People, Reflection, Wrap Up. Do not offer posters, hook stacks, or blueprint downloads as mirror reads.',
'Capability grounding rule: keep every offer tied to actions this interface can actually support in-session. Valid interpretive products: Solo Mirror, Relationship Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. Also: Set Location, Stage People, Reflection, Wrap Up. Do not offer posters, hook stacks, or blueprint downloads as mirror reads.',
'Session-evidence rule: when no document, upload, notebook, external file, or hidden tool has appeared in this conversation, continue without introducing one. Ground the next step in the active profile, staged people, current location, or the live instrument lane instead.',
'When answering relational-friction prompts (e.g., camaraderie/trust/reciprocity deficits), translate into Woven Map mechanics: field cohesion, contact coherence, contract clarity, and reciprocity load.',
'Relational-friction output shape: one symbolic diagnosis sentence grounded in map language + one operational sentence with concrete behavioral terms.',
Expand Down Expand Up @@ -766,7 +766,7 @@ export function buildPromptLines(config: PromptLinesConfig): PromptLinesResult {
relationalMappingRequested,
}),
'MANIFESTATION FIREWALL (Pre-testimony): Stay on pressure, carrying demand, clarity, and landing zone. Wait for the user to introduce specific outcome language before naming any concrete event.',
'Capability grounding rule: keep every offer tied to actions this interface can actually support in-session. Valid interpretive products: Solo Mirror, Synastry Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. Also: Set Location, Stage People, Reflection, Wrap Up. Do not offer posters, hook stacks, or blueprint downloads as mirror reads.',
'Capability grounding rule: keep every offer tied to actions this interface can actually support in-session. Valid interpretive products: Solo Mirror, Relationship Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. Also: Set Location, Stage People, Reflection, Wrap Up. Do not offer posters, hook stacks, or blueprint downloads as mirror reads.',
fieldReportResponseInvitationInstruction,
'',
'',
Expand Down
2 changes: 1 addition & 1 deletion vessel/src/components/ConstellationVaultPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ function entrySubline(entry: ConstellationEntry): string {
}
if (entry.artifact.kind === "insight_card") return entry.artifact.prompt;
if (entry.artifact.kind === "poetic_index_card") return entry.artifact.visible.prompt;
if (entry.artifact.kind === "sealed_keepsake") return entry.artifact.content.promptQuestionQuestion || "";
if (entry.artifact.kind === "sealed_keepsake") return entry.artifact.content.promptQuestion || "";
return "";
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { usePoeticCodexGenerator } from '@/hooks/raven/usePoeticCodexGenerator';
import { upsertConstellationEntry, type PoeticIndexCardArtifact } from '@/lib/raven/constellationVault';
import { sealKeepsake, addUserNote } from '@/lib/raven/keepsakeService';
import type { PoeticIndexCard } from '@/lib/raven/poetic-codex/types';
// import type { ChatMessage } from '@/hooks/useOracleChat';
import type { ChatMessage } from '@/hooks/useOracleChat';
import { extractAspectsFromProfile } from '@/lib/raven/aspectExtractor';

interface PoeticIndexCardPanelProps {
Expand Down Expand Up @@ -62,8 +62,8 @@ export function PoeticIndexCardPanel({

if (targetMessage) {
// Sealing a real message
const drivers = targetMessage.corridorSnapshot?.transitDrivers?.subjectA?.drivers?.map((d: any) => d.driver) || [];
const geometryHash = targetMessage.corridorSnapshot?.transitDrivers?.subjectA?.drivers?.[0]?.driver
const drivers = targetMessage.corridorSnapshot?.transitDrivers?.subjectA?.drivers?.map((d: any) => d) || [];
const geometryHash = targetMessage.corridorSnapshot?.transitDrivers?.subjectA?.drivers?.[0]
? `geo_${targetMessage.id.slice(0, 6)}`
: `geo_session_${targetMessage.id.slice(0, 4)}`;
Comment on lines +65 to 68

Expand Down
2 changes: 1 addition & 1 deletion vessel/src/lib/raven/__tests__/mirrorArtifactKinds.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ test('fullReadLabelForFamily maps to frontstage full-read titles', () => {
assert.equal(fullReadLabelForFamily('synastry_mirror'), 'full_synastry_mirror');
assert.equal(
MIRROR_REPORT_FAMILY_TITLE.synastry_mirror,
'Synastry Mirror Report',
'Relationship Mirror Report',
);
});

Expand Down
6 changes: 3 additions & 3 deletions vessel/src/lib/raven/__tests__/mirrorProductPrompt.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ test('taxonomy block names Solo Mirror and Opening Mirror for SOLO_MIRROR lane',
assert.match(block, /Never frontstage: Poster, Strike/i);
});

test('taxonomy block names Synastry Mirror Report for RELATIONAL_MAPPING', () => {
test('taxonomy block names Relationship Mirror Report for RELATIONAL_MAPPING', () => {
const block = buildMirrorProductTaxonomyBlock('RELATIONAL_MAPPING');
assert.match(block, /Synastry Mirror Report/);
assert.match(block, /Full Synastry Mirror/);
assert.match(block, /Relationship Mirror Report/);
assert.match(block, /Full Relationship Mirror/);
});

test('capability line lists four interpretive products', () => {
Expand Down
6 changes: 3 additions & 3 deletions vessel/src/lib/raven/degradedReplyBuilders.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,12 +225,12 @@
if (!includeLocationLine) {
return input.isRelational
? 'I am here. Ask directly or map the contact.'
: 'I am here. Ask directly, open a Solo Mirror, or start a Synastry Mirror Report.';
: 'I am here. Ask directly, open a Solo Mirror, or start a Relationship Mirror Report.';
}
if (input.field.hasKnownLocation) {
return input.isRelational
? 'I am here, and location context is already set. Ask directly, open a Relational Moment, or map the contact.'
: 'I am here, and location context is already set. Ask directly, open a Symbolic Moment Report, run a Solo Mirror, or start a Synastry Mirror Report.';
: 'I am here, and location context is already set. Ask directly, open a Symbolic Moment Report, run a Solo Mirror, or start a Relationship Mirror Report.';
}
return input.isRelational
? 'I am here. Current location is missing, but we can still work from relationship structure now or set location to open Relational Moments.'
Expand Down Expand Up @@ -355,22 +355,22 @@

const recoveryLine = input.rootCause === 'routing_failed_no_upstream_call'
? 'Ask again after confirming your primary profile is saved. If the pipeline export still shows zero runtime events, that is a capture failure — not a provider outage.'
: input.rootCause === 'natal_profile_missing'
? timingWindow
? 'Save or complete your primary profile first, then ask for the next high-valence window again.'
: 'Save or complete your primary profile first, then ask for the Symbolic Moment again.'
: input.rootCause === 'rate_limited'
? 'Wait for the provider window to reset, then ask for the timing scan again.'
: input.rootCause === 'runtime_budget_exhausted'
? 'Try a narrower window or ask again on the next turn when runtime budget resets.'
: input.rootCause === 'geometry_unavailable'
? timingWindow
? 'Confirm birth data and current location, then ask for the next high-valence window again.'
: 'Confirm birth data and current location, then ask for the Symbolic Moment again.'
: input.rootCause === 'astro_api_key_missing'
? blueprintAvailable
? 'Say "Mirror" for permanent architecture, or ask a direct question to continue.'
: 'Use Mirror, Synastry Mirror Report, or a direct question for now.'
: 'Use Mirror, Relationship Mirror Report, or a direct question for now.'

Check warning on line 373 in vessel/src/lib/raven/degradedReplyBuilders.ts

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Extract this nested ternary operation into an independent statement.

See more on https://sonarcloud.io/project/issues?id=DHCross_Shipyard&issues=AZ8QIkZ6OTjgnHXEqlGv&open=AZ8QIkZ6OTjgnHXEqlGv&pullRequest=882
: input.rootCause === 'astrology_fetch_failed'
? timingWindow
? 'Ask for the next high-valence window again once the provider reconnects.'
Expand Down
4 changes: 2 additions & 2 deletions vessel/src/lib/raven/mirrorArtifactKinds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@ export type MirrorBackstageMethod = 'hook_stack' | 'relational_hook_stack';
/** User-facing product titles. */
export const MIRROR_REPORT_FAMILY_TITLE: Record<MirrorReportFamily, string> = {
solo_mirror: 'Solo Mirror',
synastry_mirror: 'Synastry Mirror Report',
synastry_mirror: 'Relationship Mirror Report',
symbolic_moment: 'Symbolic Moment Report',
symbolic_weather: 'Symbolic Weather Report',
};

/** User-facing second-pass titles. */
export const MIRROR_FULL_READ_LABEL_TITLE: Record<MirrorFullReadLabel, string> = {
full_solo_mirror: 'Full Solo Mirror',
full_synastry_mirror: 'Full Synastry Mirror',
full_synastry_mirror: 'Full Relationship Mirror',
full_symbolic_moment: 'Full Symbolic Moment',
full_symbolic_weather: 'Full Symbolic Weather',
};
Expand Down
10 changes: 5 additions & 5 deletions vessel/src/lib/raven/mirrorProductPrompt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ function buildActiveLaneGuidance(promptMode: PromptMode): string {
].join('\n');
case 'RELATIONAL_MAPPING':
return [
'**Active product: Synastry Mirror Report** (relational / polyadic when staged).',
'**Active product: Relationship Mirror Report** (relational / polyadic when staged).',
'Name people. State direction: what A activates in B, what B activates in A, what repeats.',
'Deliver: Opening Mirror, then Full Synastry Mirror depth when invited.',
'Deliver: Opening Mirror, then Full Relationship Mirror depth when invited.',
'Do not flatten to "you both" or romantic-only clichés when the bond type is otherwise.',
].join('\n');
case 'FIELD_REPORT':
Expand All @@ -49,12 +49,12 @@ function buildActiveLaneGuidance(promptMode: PromptMode): string {
case 'SHARED_SYMBOLIC_MOMENT':
return [
'**Active product: Symbolic Moment Report** — shared /us aperture (one sky, separate landings).',
'This is the moment, not a full Synastry Mirror autopsy. Use /relationship for the map.',
'This is the moment, not a full Relationship Mirror autopsy. Use /relationship for the map.',
].join('\n');
case 'CHAT':
return [
'**Lane: Chat** — answer the turn. When offering reads, name products correctly:',
'Solo Mirror, Synastry Mirror Report, Symbolic Moment Report, Symbolic Weather Report.',
'Solo Mirror, Relationship Mirror Report, Symbolic Moment Report, Symbolic Weather Report.',
'Each uses Opening Mirror → Full Read. Do not offer "posters" or "hook stacks" as products.',
].join('\n');
default:
Expand All @@ -80,4 +80,4 @@ export function buildMirrorProductTaxonomyBlock(promptMode: PromptMode): string

/** One-line capability grounding for chat prompt lines. */
export const MIRROR_PRODUCT_CAPABILITY_LINE =
'Valid interpretive products: Solo Mirror, Synastry Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. Stage people and set location when needed. Do not offer posters, hook stacks, or blueprint downloads as mirror reads.';
'Valid interpretive products: Solo Mirror, Relationship Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. Stage people and set location when needed. Do not offer posters, hook stacks, or blueprint downloads as mirror reads.';
4 changes: 2 additions & 2 deletions vessel/src/lib/raven/persona-law.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ Every interpretive claim needs a falsifiable anchor: a user-supplied fact, a nam
User testimony wins over interpretation; when map and lived ground conflict, name the conflict and let the person relocate or reject the read.
Never invent missing geometry. Speak from the sealed payload, the user's words, or marked uncertainty.
Keep backstage language backstage. Frontstage speaks in planets, houses, aspects, thresholds, chambers, and lived terms.
Speak in one lane at a time. CHAT answers the turn. Products: Solo Mirror, Synastry Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. FIELD_REPORT is Symbolic Moment (now). SOLO_MIRROR is Solo Mirror. RELATIONAL_MAPPING is Synastry Mirror Report. Never call prose reads posters or hook stacks. Mirror passes translate sealed geometry into lived proof first; chamber depth comes later. CREATOR_MIRROR is diagnostic.
Speak in one lane at a time. CHAT answers the turn. Products: Solo Mirror, Relationship Mirror Report, Symbolic Moment Report, Symbolic Weather Report — each opens with an Opening Mirror, then its Full Read. FIELD_REPORT is Symbolic Moment (now). SOLO_MIRROR is Solo Mirror. RELATIONAL_MAPPING is Relationship Mirror Report. Never call prose reads posters or hook stacks. Mirror passes translate sealed geometry into lived proof first; chamber depth comes later. CREATOR_MIRROR is diagnostic.
Agency returns at the end of every sentence.`.trim();

// ─────────────────────────────────────────────────────────
Expand Down Expand Up @@ -222,7 +222,7 @@ Do not import current transits, Balance Meter state, timing, or Symbolic Moment
}
if (promptMode === 'RELATIONAL_MAPPING') {
return `RELATIONAL_MAPPING lane kernel:
Product: Synastry Mirror Report — Opening Mirror then Full Synastry Mirror.
Product: Relationship Mirror Report — Opening Mirror then Full Relationship Mirror.
Read the staged relational field only. Name direction (A→B, B→A, loop). Name bond type when known.
Name active people by name when available. Do not drift into solo interpretation or invent counterpart motives.
Do not say Hook Stack or poster for prose.`.trim();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ A mood-line names a feeling-state. A mechanism-line names an operation — somet
| Product | When | Two passes |
| ------- | ---- | ---------- |
| **Solo Mirror** | One person's natal / structural pattern | Opening Mirror → **Full Solo Mirror** |
| **Synastry Mirror Report** | Two or more people — any bond type | Opening Mirror → **Full Synastry Mirror** |
| **Relationship Mirror Report** | Two or more people — any bond type | Opening Mirror → **Full Relationship Mirror** |
| **Symbolic Moment Report** | Current pressure **now** | Opening Mirror → **Full Symbolic Moment** |
| **Symbolic Weather Report** | Pressure across a **dated window** | Opening Mirror → **Full Symbolic Weather** |
| **Shadow Mirror (Pro)** | The Jungian integration layer (split/reassignment) | Add-on offered **only after** a Full Read lands successfully |
Expand Down
6 changes: 3 additions & 3 deletions vessel/src/lib/raven/relationalIntent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -650,7 +650,7 @@ export function findTriadicScopeVaultProfiles(
// ─── Relational Contrast Mode ────────────────────────────────────────────────
//
// Detects when the user is asking why one person affects/unnerves/pressures
// another — NOT requesting full synastry, just architecture contrast.
// another — NOT requesting full relationship mapping, just architecture contrast.
// Examples: "why does Carrie unnerve me?", "it's easy to see why she unsettles
// me", "why do I feel that pressure around her?"

Expand Down Expand Up @@ -678,13 +678,13 @@ export const RELATIONAL_CONTRAST_FRAME = `RELATIONAL CONTRAST MODE

The user is asking why one person affects, unnerves, pressures, attracts, clashes with, or destabilizes another.

This is NOT a request for full synastry. Do not refuse because synastry geometry is not loaded.
This is NOT a request for full relationship mapping. Do not refuse because synastry geometry is not loaded.

Route to Relational Contrast Mode:
1. Identify the active anchor and the named counterpart.
2. Compare available architecture: ignition style, regulation layer, interface gate, cognitive architecture, chamber emphasis — whatever is present.
3. Explain the structural reason for the friction, attraction, or pressure pattern.
4. State the boundary clearly: "This is not full synastry. This is architecture contrast from the available material."
4. State the boundary clearly: "This is not full relationship mapping. This is architecture contrast from the available material."

If only the anchor's chart is loaded, compare against what is known or supplied about the counterpart. If the counterpart architecture is entirely absent, say what you would need to go further, then give the best bounded contrast from the anchor alone.

Expand Down
2 changes: 1 addition & 1 deletion vessel/src/test/api-smoke.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2502,7 +2502,7 @@ test('Raven chat astrology integration pins the current Best Astrology v3 host +
);
assert.match(
routeSource,
/Valid interpretive products: Solo Mirror, Synastry Mirror Report, Symbolic Moment Report, Symbolic Weather Report/,
/Valid interpretive products: Solo Mirror, Relationship Mirror Report, Symbolic Moment Report, Symbolic Weather Report/,
'chat prompt law should name the supported mirror products',
);
assert.match(
Expand Down
Loading