feat: add optional MindSearch skill orchestration
This commit is contained in:
@@ -45,6 +45,7 @@ import { createMindSpaceAuditWriter } from './mindspace-audit.mjs';
|
||||
import { assertMindSpaceRoute, mindspaceFlags } from './mindspace-flags.mjs';
|
||||
import { createMindSpaceService } from './mindspace.mjs';
|
||||
import { ensureMindSpaceConfig } from './mindspace-config.mjs';
|
||||
import { createMindSearchConfigService } from './mindsearch-config.mjs';
|
||||
import { pageInternals, inlinePrivateAssetsInHtml, normalizeWorkspaceRelativePath } from './mindspace-pages.mjs';
|
||||
import {
|
||||
createDownloadConversationPackageArtifactHandler,
|
||||
@@ -408,6 +409,8 @@ async function bootstrapUserAuth() {
|
||||
try {
|
||||
if (!isDatabaseConfigured()) return false;
|
||||
const pool = createDbPool();
|
||||
const mindSearchConfigService = createMindSearchConfigService(pool);
|
||||
await mindSearchConfigService.ensureSchema();
|
||||
authPool = pool;
|
||||
await initSchema(pool);
|
||||
await ensureMindSpaceConfig(pool, {
|
||||
@@ -542,6 +545,7 @@ async function bootstrapUserAuth() {
|
||||
h5Root: __dirname,
|
||||
defaultSignupBalanceCents: Number(process.env.H5_SIGNUP_BALANCE_CENTS ?? 500),
|
||||
subscriptionService,
|
||||
getMindSearchConfig: () => mindSearchConfigService.getEffectiveConfig(),
|
||||
provisionUserDataSpace: async ({ userId, workspaceRoot }) => {
|
||||
const service = createUserDataSpaceService({ workspaceRoot, userId, query: pool });
|
||||
return service.ensureReady();
|
||||
|
||||
Reference in New Issue
Block a user