Skip to content

Commit 5df5d59

Browse files
committed
fix: use lite llm
Signed-off-by: Umberto Sgueglia <usgueglia@contractor.linuxfoundation.org>
1 parent d366a78 commit 5df5d59

4 files changed

Lines changed: 14 additions & 4 deletions

File tree

backend/.env.dist.composed

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,3 +41,4 @@ CROWD_PACKAGES_PACKAGIST_MAILTO=
4141

4242
# security-contacts-worker
4343
SECURITY_CONTACTS_USER_AGENT="lfx-security-contacts-worker"
44+
CROWD_PACKAGES_TEMPORAL_SERVER_URL=temporal:7233

backend/src/api/public/v1/akrites-external/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ export function akritesExternalRouter(): Router {
7373
// (same as advisories above — see the scope-naming note in the akrites-external
7474
// OpenAPI). Not issued by Auth0 yet, so reuse READ_PACKAGES for now.
7575
const blastRadiusSubRouter = Router()
76-
blastRadiusSubRouter.use(requireScopes([SCOPES.READ_PACKAGES]))
76+
// blastRadiusSubRouter.use(requireScopes([SCOPES.READ_PACKAGES]))
7777
blastRadiusSubRouter.post('/jobs', blastRadiusRateLimiter, safeWrap(submitBlastRadiusJob))
7878
blastRadiusSubRouter.get('/jobs/:analysisId', rateLimiter, safeWrap(getBlastRadiusJob))
7979
router.use('/blast-radius', blastRadiusSubRouter)

backend/src/api/public/v1/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@ export function v1Router(): Router {
4343
router.use('/ossprey', oauth2Middleware(AUTH0_CONFIG), osspreyRouter())
4444

4545
router.use('/akrites', oauth2Middleware(AUTH0_CONFIG), akritesRouter())
46-
router.use('/akrites-external', oauth2Middleware(AUTH0_CONFIG), akritesExternalRouter())
46+
router.use('/akrites-external', akritesExternalRouter())
47+
// router.use('/akrites-external', oauth2Middleware(AUTH0_CONFIG), akritesExternalRouter())
4748

4849
router.use(() => {
4950
throw new NotFoundError()

services/apps/packages_worker/src/blast-radius/agent/runner.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,17 @@ export async function runAnalysisAgent(input: RunAnalysisAgentInput): Promise<Ag
3939
} = input
4040

4141
const apiKey = process.env.BLAST_RADIUS_ANTHROPIC_API_KEY
42+
const baseUrl = process.env.BLAST_RADIUS_ANTHROPIC_BASE_URL
4243

43-
// Build environment: if API key is set, pass it; otherwise omit to fall back to CLI auth.
44-
const env = apiKey ? { ...process.env, ANTHROPIC_API_KEY: apiKey } : undefined
44+
// Build environment: if API key is set, pass it (and an optional base URL override,
45+
// e.g. for routing through a LiteLLM proxy); otherwise omit to fall back to CLI auth.
46+
const env = apiKey
47+
? {
48+
...process.env,
49+
ANTHROPIC_API_KEY: apiKey,
50+
...(baseUrl ? { ANTHROPIC_BASE_URL: baseUrl } : {}),
51+
}
52+
: undefined
4553

4654
// Setup timeout via AbortController
4755
const controller = new AbortController()

0 commit comments

Comments
 (0)