Glean Chatbot
Glean Chatbot
소규모 내부 계약 문서 세트를 Glean에 인덱싱하고, Search + Chat을 통해 해당 문서에서 질문에 답하며, 동일한 흐름을 MCP 도구(ask_glean)로 노출합니다.
요구 사항
Python 3.10+
Glean 인스턴스
Indexing API 토큰
Search 및 Chat 범위의 Client API 토큰
Related MCP server: Glean Remote MCP Server
설정
리포지토리를 클론하고 들어갑니다:
git clone <your-repo-url>
cd glean-chatbot의존성을 설치합니다:
pip install -r requirements.txt예제에서
.env파일을 만들고 값을 입력합니다:
# macOS / Linux
cp .env.example .env
# Windows (PowerShell)
copy .env.example .envVariable | Required | Purpose |
| yes | 인스턴스 이름 ( |
| yes | Indexing API 토큰 |
| yes | Client API 토큰 (Search + Chat) |
| yes* |
|
| no | 데이터소스 이름 (기본값 |
| no | Glean UI에 표시되는 이름 |
| no | 모든 문서 |
.env는 config.py에 의해 (python-dotenv를 통해) 자동으로 로드됩니다. source할 필요는 없습니다.
실행
문서 인덱싱
python scripts/index_documents.py
# optional: wait until Search can find them
python scripts/index_documents.py --verifyCLI에서 질문
python scripts/ask.py "Who owns the Enronry Tony contract?"
python scripts/ask.py "What must OKLightning Tony deliver before go-live?" --top-k 3MCP (Cursor)
프로젝트 구성은 .cursor/mcp.json에 있습니다(src/mcp_server.py의 절대 경로 + 환경 변수).
편집 후 Cursor를 다시 시작하거나 MCP를 리로드하세요. 도구 이름은 ask_glean입니다.
서버를 단독으로 스모크 테스트:
python src/mcp_server.py테스트
python tests/test_pipeline.py네트워크는 사용하지 않으며 Search/Chat을 모킹합니다.
작동 방식
scripts/index_documents.py는 data/documents.json을 Indexing API를 통해 푸시합니다.
쿼리 시점에는 src/pipeline.py가 Search를 호출한 다음, (히트가 있을 때만) 해당 히트를 폐쇄형 컨텍스트로 사용해 Chat을 호출하고 답변과 출처를 반환합니다. CLI와 MCP는 둘 다 동일한 파이프라인을 호출합니다. 결과는 자체 문서로 한정됩니다. Search 결과가 없으면 답변을 임의로 만들어 내는 대신 유사한 문서 제목을 제안합니다.
참고 사항 / 제한 사항
공유 샌드박스는
datasourcesFilter를 무시합니다. 문서 ID 접두사(CUSTOM_<DATASOURCE>_Contract_)를 기준으로 클라이언트 측에서 필터링합니다.인덱싱은 비동기식입니다 — 문서가 검색 가능해지는 데 몇 분 정도 걸릴 수 있습니다.
데모 문서는
allowAnonymousAccess: true를/를 사용합니다. 프로덕션에서는 그대로 배포하지 마세요.문서
viewURL은GLEAN_URL_REGEX와 일치해야 합니다. 그렇지 않으면 인덱싱이 거부됩니다.
API 트레이드오프와 프로덕션 참고 사항은 DESIGN_NOTE.md를 참조하세요.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables semantic search and retrieval of personal and team knowledge from connected sources like Slack, Gmail, Google Drive, and Dropbox, with the ability to save new information for future recall.Apache 2.0

Glean Remote MCP Serverofficial
AlicenseNot gradedqualityCmaintenanceEnables AI assistants and developer tools to securely access and interact with an organization's enterprise knowledge, documents, and people through natural language while respecting existing access permissions.164MIT- FlicenseNot gradedqualityFmaintenanceEnables semantic search across documentation stored in Gemini FileSearchStores, returning AI-generated answers with source citations.1

Rememberizer MCP Serverofficial
AlicenseNot gradedqualityDmaintenanceEnables querying and managing personal/team internal knowledge from sources like Slack, Gmail, and Drive through semantic search and retrieval.Apache 2.0
Related MCP Connectors
Search your knowledge bases from any AI assistant using hybrid RAG.
Search and reason over your Obsidian-style Markdown vault, right from ChatGPT.
Connect your team's living knowledge base — docs, data, issues, CRM — to Claude and ChatGPT.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/tonyromero-ai/glean-chatbot'
If you have feedback or need assistance with the MCP directory API, please join our Discord server