-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathsample.env
More file actions
171 lines (139 loc) · 5.5 KB
/
sample.env
File metadata and controls
171 lines (139 loc) · 5.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
# OMOP MCP Server Configuration Template
# Copy this file to .env and modify the values according to your setup
# ============================================================================
# LOGGING AND OBSERVABILITY CONFIGURATION
# ============================================================================
# Enable/disable file logging (default: true)
# Set to false to disable all logging output
ENABLE_LOGGING=true
DEBUG=false
LOG_FILE=omcp.log
# Enable/disable Langfuse observability and tracing (default: true)
# Set to false to disable Langfuse integration
ENABLE_LANGFUSE=true
# ============================================================================
# LANGFUSE CONFIGURATION
# ============================================================================
# Langfuse public and secret keys
# Get these from your Langfuse project settings
LANGFUSE_PUBLIC_KEY="pk-lf-your-public-key-here"
LANGFUSE_SECRET_KEY="sk-lf-your-secret-key-here"
# Langfuse host URL
# Use https://cloud.langfuse.com for Langfuse Cloud
# Use http://localhost:3000 for self-hosted Langfuse
LANGFUSE_HOST="https://cloud.langfuse.com"
# Trace context file for distributed tracing (optional)
# Used for linking traces between fastomop and omcp across processes
# Default behavior (cross-platform):
# - Windows: Uses %TEMP%\.fastomop_langfuse_trace_context.json
# - macOS/Linux: Uses /tmp/.fastomop_langfuse_trace_context.json
# Only set this if you need a custom location or for cross-service coordination
# IMPORTANT: fastomop and omcp must use the same file path for trace propagation to work
#LANGFUSE_TRACE_CONTEXT_FILE=/tmp/.fastomop_langfuse_trace_context.json
# ============================================================================
# DATABASE CONFIGURATION
# ============================================================================
# Supported database types: duckdb, postgres, databricks
DB_TYPE=duckdb
# Database Read-Only Mode (recommended for production)
# Set to true to prevent accidental database modifications
DB_READ_ONLY=true
# ============================================================================
# DUCKDB CONFIGURATION (when DB_TYPE=duckdb)
# ============================================================================
# Path to your DuckDB database file
DB_PATH=/path/to/your/omop.duckdb
# ============================================================================
# POSTGRESQL CONFIGURATION (when DB_TYPE=postgres)
# ============================================================================
# PostgreSQL connection details
DB_USERNAME=your_username
DB_PASSWORD=your_password
DB_HOST=localhost
DB_PORT=5432
DB_DATABASE=your_database_name
# ============================================================================
# DATABRICKS CONFIGURATION (when DB_TYPE=databricks)
# ============================================================================
# Databricks workspace hostname (without https://)
# Example: your-workspace.cloud.databricks.com
DB_HOST=your-workspace.cloud.databricks.com
# Databricks personal access token
# Generate from: Workspace > User Settings > Access Tokens
DB_TOKEN=your-databricks-token
# SQL Warehouse HTTP path
# Find in: SQL Warehouses > Your Warehouse > Connection Details
# Example: /sql/1.0/warehouses/1234567890abcdef
DB_HTTP_PATH=your-warehouse-path
# Catalog name (Unity Catalog) or use 'hive_metastore' for legacy
# Default: hive_metastore
DB_CATALOG=hive_metastore
# Schema/database name within the catalog
# Default: default
DB_SCHEMA=default
# ============================================================================
# OMOP SCHEMA CONFIGURATION
# ============================================================================
# Schema containing OMOP CDM tables
CDM_SCHEMA=cdm
# Schema containing vocabulary tables (can be same as CDM_SCHEMA)
VOCAB_SCHEMA=vocab
# ============================================================================
# MCP SERVER CONFIGURATION
# ============================================================================
# Transport type:
# - stdio: For direct integration with MCP clients (Claude Desktop, etc.)
# - sse: For web-based clients and HTTP API access
MCP_TRANSPORT=stdio
# Host and port configuration (required for SSE transport, ignored for stdio)
MCP_HOST=localhost
MCP_PORT=8080
# ============================================================================
# EXAMPLE CONFIGURATIONS
# ============================================================================
# Example 1: DuckDB with full logging
#ENABLE_LOGGING=true
#ENABLE_LANGFUSE=true
#DB_TYPE=duckdb
#DB_PATH=/Users/username/data/omop.duckdb
#DB_READ_ONLY=true
#CDM_SCHEMA=cdm
#VOCAB_SCHEMA=vocab
#MCP_TRANSPORT=stdio
# Example 2: PostgreSQL with minimal logging
#ENABLE_LOGGING=true
#ENABLE_LANGFUSE=false
#DB_TYPE=postgres
#DB_USERNAME=omop_user
#DB_PASSWORD=secure_password
#DB_HOST=db.example.com
#DB_PORT=5432
#DB_DATABASE=omop_cdm
#DB_READ_ONLY=true
#CDM_SCHEMA=cdm_531
#VOCAB_SCHEMA=vocab
#MCP_TRANSPORT=sse
#MCP_HOST=0.0.0.0
#MCP_PORT=8080
# Example 3: Development setup with no logging
#ENABLE_LOGGING=false
#ENABLE_LANGFUSE=false
#DB_TYPE=duckdb
#DB_PATH=/tmp/test.duckdb
#DB_READ_ONLY=false
#CDM_SCHEMA=main
#VOCAB_SCHEMA=main
#MCP_TRANSPORT=stdio
# Example 4: Databricks with Unity Catalog
#ENABLE_LOGGING=true
#ENABLE_LANGFUSE=true
#DB_TYPE=databricks
#DB_HOST=your-workspace.cloud.databricks.com
#DB_TOKEN=dapixxxxxxxxxxxxxxxxxxxx
#DB_HTTP_PATH=/sql/1.0/warehouses/1234567890abcdef
#DB_CATALOG=omop_catalog
#DB_SCHEMA=cdm_531
#DB_READ_ONLY=true
#CDM_SCHEMA=cdm_531
#VOCAB_SCHEMA=cdm_531
#MCP_TRANSPORT=stdio