Skip to content
Merged
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
29 changes: 0 additions & 29 deletions apps/web/src/types/session.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,32 +16,3 @@ export interface Artifact {
prNumber?: number
createdAt: number
}

export interface Task {
content: string
status: "pending" | "in_progress" | "completed"
activeForm?: string
}

export interface FileChange {
filename: string
additions: number
deletions: number
}

export interface ChildSession {
id: string
description: string
prNumber?: number
prState?: "open" | "merged" | "closed" | "draft"
platform?: string
}

export interface SessionMetadata {
title: string
model?: string
branchName?: string
projectTag?: string
createdAt: number
updatedAt?: number
}
2 changes: 0 additions & 2 deletions packages/api/src/server/background/db/auth-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,5 +119,3 @@ export const getPublicAuthProviderRegistry = Effect.fn("authConfig.getPublicAuth
) satisfies PublicAuthProviderRegistry
},
)

export const getStoredAuthProviderRegistryForTesting = getStoredAuthProviderRegistry
23 changes: 0 additions & 23 deletions packages/api/src/server/background/db/repo-secrets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,34 +68,11 @@ function normalizeTags(tags: readonly string[] | undefined): string[] {
return [...normalized].sort()
}

const popularTagOrder = Order.combine(
Order.mapInput(Order.flip(Order.Number), (entry: readonly [string, number]) => entry[1]),
Order.mapInput(localeStringOrder, (entry: readonly [string, number]) => entry[0]),
)

const tagStatOrder = Order.combine(
Order.mapInput(Order.flip(Order.Number), (row: { tag: string; count: number }) => row.count),
Order.mapInput(localeStringOrder, (row: { tag: string; count: number }) => row.tag),
)

export function rankPopularTags(secrets: readonly SecretMetadata[], limit = 5): string[] {
const counts = new Map<string, number>()
secrets.forEach((secret) =>
secret.tags.forEach((tag) => {
const trimmed = tag.trim()
Option.match(Option.fromNullishOr(trimmed).pipe(Option.filter(Boolean)), {
onNone: () => undefined,
onSome: (value) => counts.set(value, (counts.get(value) ?? 0) + 1),
})
}),
)

return [...counts.entries()]
.sort(popularTagOrder)
.slice(0, limit)
.map(([tag]) => tag)
}

export function filterSecretMetadata(
secrets: readonly SecretMetadata[],
options?: { q?: string; tags?: readonly string[] },
Expand Down
2 changes: 0 additions & 2 deletions packages/api/src/server/effect/services/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,5 +154,3 @@ export function requestFromSource(request: HttpServerRequest.HttpServerRequest)
),
)
}

export const getWebRequest = Effect.map(CurrentRequest, requestFromSource)
9 changes: 0 additions & 9 deletions packages/api/src/server/effect/services/middleware.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,3 @@
import type { ApiEnv } from "infra/types/env"
import { D1Drizzle } from "../db/d1-drizzle"
import { CloudflareContext } from "./cloudflare"

export interface CloudflareBindings {
env: ApiEnv
ctx: ExecutionContext
}

export const getCloudflareBindings = CloudflareContext

export const getD1Drizzle = D1Drizzle
9 changes: 0 additions & 9 deletions packages/api/src/server/effect/services/observability.ts
Original file line number Diff line number Diff line change
Expand Up @@ -492,10 +492,6 @@ export function annotateCurrentUserIdentity(identity: {
})
}

export function annotateCurrentUserId(userId: string) {
return annotateCurrentUserIdentity({ userId })
}

export function observabilityLayer(options: {
readonly logFormat: "pretty" | "json"
readonly consoleOutputEnabled: boolean
Expand All @@ -515,11 +511,6 @@ export function observabilityLayer(options: {
)
}

export function resetApiTelemetryForTests(): void {
// Test helper retained for callers that reset global observability state.
// Cloudflare-native export is configured on the Worker and has no SDK cache to clear.
}

export function makeEffectLoggerLayer(options: {
readonly stageMetadataInput: StageMetadataInput
readonly workerName: string
Expand Down
21 changes: 0 additions & 21 deletions packages/shared/src/models.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,4 @@
import * as Match from "effect/Match"
import { buildRuntimeModelOptions, SHARED_PROVIDER_CATALOG } from "./provider-config"

export interface ModelDisplayInfo {
id: string
name: string
}

export interface ModelCategory {
category: string
models: ModelDisplayInfo[]
}

export const MODEL_OPTIONS: ModelCategory[] = buildRuntimeModelOptions(SHARED_PROVIDER_CATALOG).map(
(group) => ({
category: group.category,
models: group.models.map((model) => ({
id: model.id,
name: model.name,
})),
}),
)

export function normalizeModelId(modelId: string): string {
return Match.value(modelId).pipe(
Expand Down
1 change: 0 additions & 1 deletion scripts/releases/github-repo.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
export const SOLZERO_GITHUB_REPO = "SolZeroAI/platform" as const
export const SOLZERO_GITHUB_URL = `https://github.com/${SOLZERO_GITHUB_REPO}`
Loading