Skip to content

# Pull Request: develop → main#36

Merged
Yoo-SH merged 132 commits into
mainfrom
develop
Aug 21, 2025
Merged

# Pull Request: develop → main#36
Yoo-SH merged 132 commits into
mainfrom
develop

Conversation

@Yoo-SH

@Yoo-SH Yoo-SH commented Aug 21, 2025

Copy link
Copy Markdown
Member

Overview

Release Version: v1.0.0
Target Branch: main ← develop
Scheduled Release Date: 2025-08-22

This is the first official release of the OpenContext project. All core features including document processing pipeline, MCP adapter, and admin UI are fully implemented and ready for production use.

Major Changes

New Features

  • Complete Document Processing Pipeline - PARSING → CHUNKING → EMBEDDING → INDEXING stages
  • MCP Adapter and Tools - Implementation of find_knowledge and get_content MCP tools
  • Admin Dashboard UI - Complete React + TypeScript based management interface
  • Hybrid Search Engine - Elasticsearch BM25 + vector similarity search
  • MinIO-based File Storage - Document upload and management system
  • Ollama Embedding Integration - Vector generation through LangChain4j

Improvements

  • H1-based Chunking Strategy - Header-based document segmentation for semantic preservation
  • Batch Processing Optimization - Enhanced performance for embedding and indexing
  • Real-time Status Monitoring - Live tracking of document processing progress
  • Responsive UI/UX - Interface optimized for various screen sizes

Bug Fixes

  • Document Deletion Pipeline Fix - Resolved DELETING status validation issues
  • CORS Configuration Fix - Resolved frontend-backend communication issues
  • UTF-8 Encoding Fix - Improved Korean character processing
  • Docker Service Connectivity Fix - Resolved inter-container communication issues

Security

  • API Key Authentication System - Enhanced security for admin endpoints
  • Spring Security Integration - Endpoint-specific access control
  • Dependency Security Vulnerability Fixes - Applied latest security patches

Included Commits/PRs

PR Number Title Author Type
#34 [Documentation] feat comprehensive CONTRIBUTING.md and Demo movie @Yoo-SH Documentation
#33 docs: improve documentation structure and open source standards @qowlgur121 Documentation
#25 hotfix: implement document deletion pipeline @Yoo-SH Bug Fix
#24 improve: optimize admin dashboard statistics and user experience @qowlgur121 Improvement
#23 fix: resolve Content Viewer text overflow and update branding elements @qowlgur121 Bug Fix
#20 hotfix: Improve search quality by fixing code chunking semantic loss @Yoo-SH Bug Fix
#19 Feature/docker config update @kAYI0019 Infrastructure
#18 feat: implement complete admin UI for OpenContext management @qowlgur121 Feature
#17 enhance: increase default search results from 5 to 50 @qowlgur121 Improvement
#16 fix: file upload UI issues in Swagger documentation @qowlgur121 Bug Fix
#15 Fix unstructured API config and update Docker setup @kAYI0019 Infrastructure
#14 fix: resolve Docker service connectivity issues @qowlgur121 Bug Fix
#13 feat: implement complete MCP search and retrieval API with hybrid search engine @qowlgur121 Feature
#12 Feature/ingestion pipeline @Yoo-SH Feature
#11 feat: implement MCP adapter, add mock server, and improve configs @kAYI0019 Feature
#10 Feature/min io @Yoo-SH Feature
#9 feat: implement structured chunk data structures and development security config @qowlgur121 Feature
#8 Fix/core build error @Yoo-SH Bug Fix
#7 feat: implement structured chunk data structures and development security config @qowlgur121 Feature
#6 feat: Implement entity database modeling with PostgreSQL entities and repositories @qowlgur121 Feature
#5 feat: Implement common modules @kAYI0019 Feature
#4 feat: implement structured chunk data structures and development security config @qowlgur121 Feature
#3 feat: setup project foundation with dependencies and build configuration @qowlgur121 Infrastructure
#2 feat: setup project foundation with dependencies and build configuration @qowlgur121 Infrastructure
#1 Initial setup Docker and project structure @Yoo-SH Infrastructure

Testing

Automated Testing

  • Unit tests passed
  • Integration tests passed
  • E2E tests passed
  • Performance tests passed

Manual Testing

  • Functional testing completed
  • Cross-browser testing completed
  • Mobile testing completed
  • Accessibility testing completed

Test Environments

  • Development Environment: Tested and verified
  • Staging Environment: Tested and verified
  • Production Environment: Pending deployment

Performance & Metrics

  • Build Time: Improved through Gradle optimization and dependency cleanup
  • Bundle Size: Admin UI optimized for production builds
  • Loading Speed: Enhanced through React Query caching and optimization
  • Memory Usage: Reduced through batch processing optimization

Breaking Changes

  • API changes present - New authentication system introduced
  • Database schema changes - Flyway migrations V1 and V2 included
  • Configuration file changes required - application.yml structure changes
  • Environment variable changes required - Docker environment variables added

Change Details:

- API key authentication required (admin endpoints)
- New database table structure (source_documents, document_chunks)
- Elasticsearch index configuration changes
- MinIO configuration additions
- Ollama connection configuration changes

Deployment Checklist

Pre-deployment Preparation

  • Database migration scripts prepared - Flyway V1 and V2 migrations ready
  • Environment variable updates checked - Docker environment variables verified
  • Configuration file changes verified - application.yml configuration verified
  • CDN cache invalidation plan established - Static asset cache invalidation plan established
  • Rollback plan established - Database rollback and service downgrade plan established

Post-deployment Monitoring

  • Error log monitoring plan - ELK stack monitoring plan established
  • Performance metrics monitoring plan - Prometheus + Grafana monitoring plan established
  • User feedback collection plan - Admin UI feedback collection system built

Documentation

  • README.md updated - Project overview and installation guide completed
  • API documentation updated - Swagger/OpenAPI documentation completed
  • User guide updated - Admin UI usage guide completed
  • Developer guide updated - CONTRIBUTING.md and development guide completed
  • CHANGELOG.md updated - Commit history based change documentation completed

Reviewers & Approvals

Required Reviewers:

  • @Yoo-SH - Project lead and backend architecture
  • @qowlgur121 - Frontend and UI/UX lead
  • @kAYI0019 - MCP adapter and infrastructure lead

Additional Reviewers:

  • @jihyeok - Quality assurance and testing lead
  • @copilot - AI code review and quality validation

Related Links

Important Notes

  • Recommended deployment time: 2-4 AM (minimum traffic period)
  • Features requiring special monitoring: Document processing pipeline, search engine
  • Expected downtime: None (zero-downtime deployment)
  • Emergency contact: @Yoo-SH (Project lead)

Final Checklist

Please verify all of the following before deployment:

  • All CI/CD pipelines passed successfully - GitHub Actions passed
  • Code review completed and approved - Team member code review completed
  • All test cases passed - Unit/integration/E2E tests passed
  • Documentation updates completed - All documentation updates completed
  • Breaking changes pre-announced - API changes pre-announced
  • Deployment and rollback plans established - Deployment and rollback plans established

This PR represents the first official release of the OpenContext project, providing complete functionality ready for production use.

qowlgur121 and others added 30 commits August 8, 2025 20:17
- Add root-level .gitignore for Docker volumes and system files
- Add core/.gitignore for Spring Boot Java backend
- Add mcp-adapter/.gitignore for Node.js MCP adapter
- Prevent tracking of build artifacts, logs, and environment files
- Spring Boot: 3.3.4 → 3.3.11
- LangChain4j: 0.34.0 → 0.36.2
- SpringDoc OpenAPI: 2.5.0 → 2.7.0
- MinIO: 8.5.7 → 8.5.12
- TestContainers BOM: 1.19.3 → 1.20.4
- Make gradlew executable for consistent build environment

Verified compatibility through successful Docker build process.
Replace deprecated $buildDir with layout.buildDirectory.dir() for Gradle 8+ compatibility
…nd-dependencies

feat: setup project foundation with dependencies and build configuration
- Add gradle-wrapper.jar for Gradle 8.5 execution
- Add gradlew.bat for Windows environment support
- Add CommonResponse: standard API response format
- Add PageResponse: pagination response DTO
- Add unit tests for CommonResponse and PageResponse
- add JpaAuditingConfig for automatic entity timestamping
- add AsyncConfig with dedicated thread pools for ingestion and general tasks
- add WebConfig to enable CORS for local development environment
- add IngestionStatus to define the document processing lifecycle
- add ErrorCode to standardize API error responses
- add BusinessException to represent custom business errors
- add GlobalExceptionHandler to catch all exceptions and return a standard CommonResponse
- Replace QueryDSL with OpenFeign fork to fix SQL injection vulnerability
- Update DJL and Commons Lang3 to latest secure versions
- Modernize QueryDSL configuration for Spring Boot 3.3 compatibility
- Fix deprecated buildDir and annotation processor warnings
- Update gradlew script with latest Gradle wrapper improvements
- Add missing gradle-wrapper.jar for self-contained builds
- Include gradlew.bat for Windows development support
- Ensures all team members can build without local Gradle installation
- Set platform: linux/amd64 for all Docker services
- Resolves compatibility issues on Apple Silicon (M1/M2) machines
- Ensures consistent behavior across different hardware architectures
…repositories

- Add IngestionStatus enum with complete document processing lifecycle states
- Implement SourceDocument entity with file metadata and ingestion tracking
- Implement DocumentChunk entity with hierarchical parent-child relationships
- Create SourceDocumentRepository with advanced query methods for status filtering
- Create DocumentChunkRepository with hierarchy navigation and cascade operations
- Add comprehensive Flyway migration V1 for PostgreSQL table creation with indexes
- Implement complete test suite with TestContainers integration testing
- Include entity unit tests with Builder pattern validation
- Add repository integration tests with real PostgreSQL container testing
- Cover CASCADE delete operations, hierarchy queries, and performance optimizations

Resolves #4
- Remove redundant 'core' package nesting (com.opencontext.core.* → com.opencontext.*)
- Eliminate duplicate IngestionStatus enum, use team member's implementation
- Maintain full entity relationship functionality and test coverage
- Update all imports to reflect new package structure

This resolves package structure inconsistencies and enables seamless
integration with common modules established in PR #5.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…atabase-modeling

feat: Implement entity database modeling with PostgreSQL entities and repositories
- Implement StructuredChunk with embedding support and metadata
- Add hierarchical navigation with breadcrumbs and level tracking
- Create response objects for search results and content delivery
- Include token counting for content length management
- Allow unrestricted access to API documentation endpoints
- Enable MCP API access without authentication
- Configure stateless session management for REST APIs
- Prepare foundation for API key authentication on admin endpoints
- Configure PostgreSQL connection with optimized pool settings
- Add Elasticsearch, Ollama, and MinIO service endpoints
- Enable Flyway baseline migration for existing databases
- Set appropriate logging levels for development debugging
…ed-chunk-mock-data-generation

feat: implement structured chunk data structures and development security config
- Implement X-API-KEY header validation for /api/v1/sources endpoints
- Add proper error responses for missing/invalid API keys
- Support configurable API key via application properties
- Secure admin APIs while keeping MCP APIs public
- Configure MinIO client bean with endpoint and credentials
- Support configurable properties via application.yml
- Enable file storage operations for document management
- Add ApiKeyAuthenticationFilter to Spring Security filter chain
- Configure protected endpoints for admin APIs (/api/v1/sources)
- Keep MCP APIs public while securing admin operations
- Enable X-API-KEY header validation for document management
- Add SourceDocumentDto for document list API response
- Add SourceUploadResponse for file upload API response
- Add FileStorageService for MinIO file operations
- Add SourceDocumentService for document lifecycle management
- Implement upload, retrieval, resync, and deletion operations
- Support asynchronous document processing pipeline
- Add DocsSourceController interface with Swagger documentation
- Add SourceController implementation for document management
- Implement upload, list, resync, and delete endpoints
- Support /api/v1/sources REST API with proper error handling
Yoo-SH and others added 17 commits August 21, 2025 20:07
- Add direct markdown processing logic to handle header recognition
- Implement postProcessMarkdownElements for structure correction
- Ensure only H1 headers (#) are recognized as section titles
- Improve code block preservation and prevent fragmentation
- Replace hierarchical chunking with title-based chunking using H1 headers only
- Each H1 section becomes a single large chunk without splitting
- Add token count estimation for better chunk size monitoring
- Improve chunk content preservation by removing arbitrary size limits
- Decrease batch-size to 2 to handle increased chunk sizes
- Prevent Ollama timeout issues with larger content chunks
- Improve processing stability for H1-based chunking strategy
…20)

Improve search quality by fixing code chunking semantic loss
- Reduce README from 776 to 241 lines following open source best practices
- Remove excessive emojis and marketing language for professional tone
- Reframe two-phase search in terms of MCP token efficiency
- Update installation to reflect automatic model downloading
- Focus on Quick Start, Tech Stack, and Contributing sections
- Maintain clear value proposition while improving readability
- Create detailed core/README.md for backend developers
- Include architecture overview with clear package structure
- Document all API endpoints with authentication requirements
- Add database schema with PostgreSQL and Elasticsearch mappings
- Provide development setup, testing, and troubleshooting sections
- Include monitoring, performance tuning, and security considerations
…mentation

docs: improve documentation structure and open source standards
- Add detailed contributing guidelines with code standards and community guidelines
- Include Git Flow based branch strategy with naming conventions
- Define pull request guidelines with templates and review process
- Establish commit message conventions following conventional commits
- Provide step-by-step workflow for feature development, hotfixes, and releases
- Add code review guidelines and completion criteria for maintainers
[Documentation] feat comprehensive CONTRIBUTING.md and Demo movie for open-source development
- Update JavaDoc comments in controllers and services
- Translate Korean log messages to English for consistency
- Remove emoji characters from all log statements across service classes
Removes emoji characters from all log messages across service classes to improve log readability and maintain professional appearance in production environments.
@Yoo-SH Yoo-SH added the enhancement New feature or request label Aug 21, 2025

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR represents the first official release of the OpenContext project (v1.0.0), bringing the develop branch into main with complete functionality for document processing, semantic search, and management interfaces.

Key changes:

  • Complete document ingestion pipeline with five stages: PARSING → CHUNKING → EMBEDDING → INDEXING → COMPLETED
  • Full-featured MCP (Model Context Protocol) adapter with TypeScript implementation for AI client integration
  • Comprehensive database schema with Flyway migrations and entity relationship management

Reviewed Changes

Copilot reviewed 102 out of 109 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
mcp-adapter/* Complete TypeScript MCP adapter implementation with HTTP/stdio transport support
core/src/main/resources/db/migration/* Database schema creation and enhancement migrations
core/src/main/java/com/opencontext/service/* Core business logic services for document processing pipeline
core/src/main/java/com/opencontext/repository/* JPA repositories with comprehensive query methods
core/src/main/java/com/opencontext/entity/* JPA entities with hierarchical document chunk modeling
core/src/main/resources/application*.yml Environment-specific configuration updates
docker-compose.yml Infrastructure updates including Kibana and improved service configuration

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@@ -0,0 +1,681 @@
package com.opencontext.service;

Copilot AI Aug 21, 2025

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The leading whitespace before 'package' declaration is unnecessary and inconsistent with Java conventions. Remove the leading spaces.

Suggested change
package com.opencontext.service;
package com.opencontext.service;

Copilot uses AI. Check for mistakes.
ALTER TABLE document_chunks ADD COLUMN source_document_uuid UUID;

-- Add parent_chunk_uuid column (for parent relationship as UUID)
ALTER TABLE document_chunks ADD COLUMN parent_chunk_uuid UUID;

Copilot AI Aug 21, 2025

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding columns that duplicate existing foreign key relationships (source_document_uuid, parent_chunk_uuid) creates data redundancy. Consider whether these additional UUID columns are necessary given that the entity already has proper JPA relationships via source_document_id and parent_chunk_id.

Suggested change
ALTER TABLE document_chunks ADD COLUMN parent_chunk_uuid UUID;
-- REMOVED: ALTER TABLE document_chunks ADD COLUMN source_document_uuid UUID;
-- Add parent_chunk_uuid column (for parent relationship as UUID)
-- REMOVED: ALTER TABLE document_chunks ADD COLUMN parent_chunk_uuid UUID;

Copilot uses AI. Check for mistakes.

try {
Map<String, Object> searchQuery = buildHybridSearchQuery(query, queryEmbedding, topK);
String searchUrl = elasticsearchUrl + "/" + indexName + "/_search";

Copilot AI Aug 21, 2025

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

String concatenation for URL construction is error-prone and doesn't handle URL encoding. Consider using UriComponentsBuilder or similar URL building utilities for safer URL construction.

Suggested change
String searchUrl = elasticsearchUrl + "/" + indexName + "/_search";
String searchUrl = UriComponentsBuilder.fromHttpUrl(elasticsearchUrl)
.pathSegment(indexName)
.pathSegment("_search")
.toUriString();

Copilot uses AI. Check for mistakes.
@Yoo-SH Yoo-SH changed the title Release v.1.0.0 # Pull Request: develop → main Aug 21, 2025

@qowlgur121 qowlgur121 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All feedback addressed. Approving this PR.

@kAYI0019 kAYI0019 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you

@Yoo-SH
Yoo-SH merged commit f6ba43d into main Aug 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants