mirror of
https://github.com/simstudioai/sim.git
synced 2026-01-08 22:48:14 -05:00
v0.4.6: kb improvements, posthog fixes
This commit is contained in:
@@ -265,9 +265,8 @@ async function handleS3PresignedUrl(
|
||||
)
|
||||
}
|
||||
|
||||
// For chat images, knowledge base files, and profile pictures, use direct URLs since they need to be accessible by external services
|
||||
const finalPath =
|
||||
uploadType === 'chat' || uploadType === 'knowledge-base' || uploadType === 'profile-pictures'
|
||||
uploadType === 'chat' || uploadType === 'profile-pictures'
|
||||
? `https://${config.bucket}.s3.${config.region}.amazonaws.com/${uniqueKey}`
|
||||
: `/api/files/serve/s3/${encodeURIComponent(uniqueKey)}`
|
||||
|
||||
|
||||
@@ -89,7 +89,6 @@ export const env = createEnv({
|
||||
TELEMETRY_ENDPOINT: z.string().url().optional(), // Custom telemetry/analytics endpoint
|
||||
COST_MULTIPLIER: z.number().optional(), // Multiplier for cost calculations
|
||||
LOG_LEVEL: z.enum(['DEBUG', 'INFO', 'WARN', 'ERROR']).optional(), // Minimum log level to display (defaults to ERROR in production, DEBUG in development)
|
||||
POSTHOG_ENABLED: z.boolean().optional(), // Enable PostHog analytics and session recording
|
||||
|
||||
// External Services
|
||||
BROWSERBASE_API_KEY: z.string().min(1).optional(), // Browserbase API key for browser automation
|
||||
|
||||
@@ -239,10 +239,6 @@ const nextConfig: NextConfig = {
|
||||
return redirects
|
||||
},
|
||||
async rewrites() {
|
||||
if (!isTruthy(env.POSTHOG_ENABLED)) {
|
||||
return []
|
||||
}
|
||||
|
||||
return [
|
||||
{
|
||||
source: '/ingest/static/:path*',
|
||||
|
||||
Reference in New Issue
Block a user