OptionalenableCalendarAwareness?: booleanOptionalenableEpisodePatientBlock?: booleanOptionalenableExpandedStatuses?: booleanOptionalenableIntentAwarePlanning?: booleanOptionalenableMetadataAwareGate?: booleanOptionalenablePerQuestionInstructions?: booleanOptionalenableQueryHydration?: booleanOptionalenableReviewCriteriaInDocumentSelection?: booleanOptionalenableRunConstantPrefix?: booleanOnly read when enableV3PassFailRunner is on — it configures the v3 runner, not v2.
OptionalenableStatusReconciliation?: booleanOptionalenableSubClaimFanOut?: booleanOnly read when enableV3PassFailRunner is on — it configures the v3 runner, not v2.
OptionalenableSummaryTableShortcut?: booleanOptionalenableThinRetrievalBailout?: booleanOptionalenableTimeFilteringInChartReview?: booleanOptionalenableUnlockedRetrieval?: booleanOptionalenableV3PassFailRunner?: booleanOptionalopts: { promptCacheKey?: string }
Constructs the
ChatOpenAIinstance that powers a chart-review run.The values mirror v1's
circlehealthai-web/app/api/chart-review/run-v2/route.tsverbatim (gpt-4.1, temperature 0.1, no streaming, 3 retries).maxTokensis sourced from the resolvedChartReviewSettingsso LD overrides flow through.Lives here (rather than in the trpc handler) so the
@langchain/openaidependency stays confined to@repo/legacy.promptCacheKeyroutes same-prefix traffic to one machine so the automatic prompt cache is realized at volume. Pass it only from single-purpose call sites: the shared run-wide instance serves several prompts, and one key across different prefixes just dilutes the routing.