Gitlab Bridge Adapter
Find a file
me 84abdf2e20
All checks were successful
Node.js Test and Build / run-node-tests (push) Successful in 1m0s
15 enhance persisted conversations
2026-01-05 07:28:28 +09:00
.forgejo/workflows Remove Docker build step 2025-12-17 15:47:14 +09:00
tests conversation archiving and improve code block handling 2025-12-24 15:33:21 +09:00
.gitignore add CICD pipeline 2025-12-12 18:21:07 +09:00
package-lock.json adding tests 2025-12-09 11:12:59 +09:00
package.json adding tests 2025-12-09 11:12:59 +09:00
proxy.js 15 enhance persisted conversations 2026-01-05 07:28:28 +09:00
Readme.md documentation update 2025-12-15 19:49:35 +09:00

GitLab Duo <-> Ollama Bridge

This project acts as a proxy server that allows local AI clients (like IntelliJ IDEA with the Ollama plugin) to communicate with GitLab Duo.

It mocks the Ollama API (/api/tags, /api/chat) and translates requests into GitLab GraphQL mutations and ActionCable WebSocket subscriptions.

Prerequisites

  1. Node.js (v18 or higher recommended).
  2. A GitLab.com account with access to Duo features.
  3. A valid GitLab Personal Access Token (PAT) or an active session.

Configuration

Because GitLab Duo relies on WebSocket subscriptions that are normally handled by the browser, you must export your active session credentials as environment variables.

1. Get your Session Data

  1. Log in to GitLab.com.
  2. Open your browser's Developer Tools (F12) -> Network tab.
  3. Refresh the page.
  4. Click on the first request (e.g., gitlab.com).
  5. Look at the Request Headers:
    • Copy the whole value of Cookie.
    • Look for x-csrf-token (sometimes found in the HTML source or subsequent XHR requests).

2. Set Environment Variables

Export the following variables in your terminal before running the app: