# dat | Junjie.M | Knowledge Base | Instagit

GitHub Stars: 0

Repository: https://github.com/junjiem/dat

---

## Articles

### [How to Troubleshoot Common Semantic Model Configuration Errors in Dat](/junjiem/dat/how-to-troubleshoot-common-semantic-model-configuration-errors)

Troubleshoot common Dat semantic model configuration errors with pre-build, model-level, and runtime checks. Catch duplicate names and invalid SQL before deployment.

- Tags: how-to-guide
- Published: 2026-03-05

### [How the Streaming Response Works in the OpenAPI Server](/junjiem/dat/how-does-the-streaming-response-work-in-the-openapi-server)

Discover how the OpenAPI server leverages Spring's SseEmitter for efficient streaming responses. Learn about asynchronous event processing and keep-alive pings to prevent timeouts.

- Tags: deep-dive
- Published: 2026-03-05

### [How to Configure Azure OpenAI as the LLM Provider in DAT](/junjiem/dat/how-to-configure-azure-openai-as-the-llm-provider)

Easily configure Azure OpenAI as your LLM provider in DAT. Follow our clear steps to add the Maven dependency, declare your model in project.yaml, and provide the necessary Azure OpenAI parameters.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Implement Custom Dimension Types in DAT Beyond Time and Categorical](/junjiem/dat/how-to-implement-custom-dimension-types-beyond-time-and-categorical)

Learn to implement custom dimension types in DAT beyond time and categorical. Extend DimensionType, define parameters, add validation, generate SQL, and register your type for powerful data analysis.

- Tags: how-to-guide
- Published: 2026-03-05

### [How Semantic Model Validation Works in DAT: A Deep Dive into PreBuildValidator](/junjiem/dat/how-does-the-semantic-model-validation-prebuildvalidator-work)

Explore DAT's PreBuildValidator for semantic model validation. Learn how dry-run SQL queries ensure schema accuracy and data type integrity before code generation.

- Tags: deep-dive
- Published: 2026-03-05

### [How to Migrate from DuckDB to PostgreSQL in a DAT Project](/junjiem/dat/how-to-migrate-from-duckdb-to-postgresql-in-an-existing-dat-project)

Easily migrate from DuckDB to PostgreSQL in your DAT project. Learn how to add the postgresql adapter update your config and migrate your data with simple steps.

- Tags: migration-guide
- Published: 2026-03-05

### [How to Optimize Embedding Model Performance for Large Datasets in dat](/junjiem/dat/how-to-optimize-embedding-model-performance-for-large-datasets)

Optimize embedding model performance for large datasets in dat. Tune batch sizes, reuse EmbeddingModel instances, and use vector database bulk writes for better throughput.

- Tags: performance
- Published: 2026-03-05

### [How the DAT MCP Server Integrates with Claude Desktop: Architecture and Setup Guide](/junjiem/dat/how-does-the-mcp-server-integrate-with-claude-desktop)

Learn how the DAT MCP server integrates with Claude Desktop via HTTP/SSE endpoints and the Model Context Protocol. Execute SQL queries and data analysis using natural language.

- Tags: architecture
- Published: 2026-03-05

### [How to Secure the OpenAPI Server with Authentication in DAT](/junjiem/dat/how-to-secure-the-openapi-server-with-authentication)

Secure your DAT OpenAPI server with Spring Security HTTP Basic authentication. Learn how to add Spring Security, configure authentication, and protect your API endpoints.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Handle Time Dimension Filters in Natural Language Queries with Dat](/junjiem/dat/how-to-handle-time-dimension-filters-in-natural-language-queries)

Master time dimension filters in natural language queries. Learn how Dat uses a human-in-the-loop workflow to clarify date ranges and generate precise SQL for your data.

- Tags: how-to-guide
- Published: 2026-03-05

### [How ProjectBuilder Builds and Validates a DAT Project: A Deep Dive into the junjiem/dat SDK](/junjiem/dat/how-does-the-projectbuilder-build-and-validate-the-dat-project)

Discover how junjiem/dat ProjectBuilder builds and validates DAT projects. Learn about its seven-step pipeline, fingerprinting, and semantic validation for artifact persistence.

- Tags: deep-dive
- Published: 2026-03-05

### [How to Configure Multiple Agents with Different LLM Providers in DAT](/junjiem/dat/how-to-configure-multiple-agents-with-different-llm-providers)

Learn to configure multiple agents with different LLM providers in DAT. Define LLMs in the global array and reference them in agent configurations for flexible model usage.

- Tags: how-to-guide
- Published: 2026-03-05

### [How ContentStore Indexes and Retrieves QuestionSql Pairs in DAT](/junjiem/dat/how-does-the-contentstore-index-and-retrieve-questionsql-pairs)

Learn how DAT ContentStore indexes QuestionSql pairs using embeddings and JSON metadata for efficient retrieval. Understand the similarity search and deserialization process.

- Tags: internals
- Published: 2026-03-05

### [How to Add a Custom Reranker Using the RerankingModel Interface in Dat](/junjiem/dat/how-to-add-a-custom-reranker-using-the-rerankingmodel-interface)

Learn to add a custom reranker in Dat by implementing the ScoringModelFactory interface and configuring dat.yaml. Enhance your search relevance with custom logic.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Debug SQL Generation Issues Using Semantic SQL Logging in DAT](/junjiem/dat/how-to-debug-sql-generation-issues-using-semantic-sql-logging)

Debug SQL generation issues with DAT semantic SQL logging. Inspect intermediate SQL from the LLM before dialect conversion to identify model or converter errors.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Configure PGVector as the Vector Store Backend in Dat](/junjiem/dat/how-to-configure-pgvector-as-the-vector-store-backend)

Configure PGVector as your Dat vector store backend. Learn how to set your vector store type and provide PostgreSQL connection details for seamless integration.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Use Jinja Templates in Semantic Models for Row-Level Security in Dat](/junjiem/dat/how-to-use-jinja-templates-in-semantic-models-for-row-level-security)

Learn to implement row-level security in Dat semantic models using Jinja 2 expressions. Inject static SQL filters with pre-build rendering and security context variables.

- Tags: how-to-guide
- Published: 2026-03-05

### [How HITL (Human-in-the-Loop) Works in the AskdataAgent Workflow](/junjiem/dat/how-does-hitl-human-in-the-loop-work-in-the-askdataagent-workflow)

Understand how HITL in AskdataAgent works by pausing LLM execution for user input or tool approval via real time stream events. Learn more about asynchronous CompletableFuture primitives.

- Tags: deep-dive
- Published: 2026-03-05

### [How to Implement a Custom EmbeddingModelFactory for a New Embedder in DAT](/junjiem/dat/how-to-implement-a-custom-embedding-model-factory-for-a-new-embedder)

Implement a custom EmbeddingModelFactory for your new embedder in DAT. Learn to define typed configs and register your factory using ServiceLoader for seamless integration.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Configure Connection Pooling for MySQL in dat_project.yaml](/junjiem/dat/how-to-configure-connection-pooling-for-mysql-in-dat_project.yaml)

Learn to configure MySQL connection pooling in dat_project.yaml. Set pool parameters like maxPoolSize directly in the db.configuration.url connection string for efficient database management.

- Tags: how-to-guide
- Published: 2026-03-05

### [How to Add a Custom Database Adapter in DAT Using SPI: A Complete Implementation Guide](/junjiem/dat/how-to-add-a-custom-database-adapter-in-dat-using-spi)

Learn to add a custom database adapter in DAT using SPI. Implement DatabaseAdapterFactory, extend GenericSqlDatabaseAdapter for JDBC, and register your factory for seamless integration. Get the complete guide.

- Tags: how-to-guide
- Published: 2026-03-05

