Skip to content

Create a basic devcontainer and simple chat app#1

Open
ngocminh-dev wants to merge 4 commits into
MissingCorner:mainfrom
ngocminh-dev:nminh/simple-chat
Open

Create a basic devcontainer and simple chat app#1
ngocminh-dev wants to merge 4 commits into
MissingCorner:mainfrom
ngocminh-dev:nminh/simple-chat

Conversation

@ngocminh-dev
Copy link
Copy Markdown

No description provided.

@chilinh chilinh requested review from chilinh and Copilot September 18, 2025 01:33
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request creates a basic development container setup and implements a simple chat application with a React frontend and FastAPI backend. The chat app enables real-time communication with an AI model hosted via LM Studio using WebSocket connections for streaming responses.

  • Sets up a complete devcontainer environment with Python 3.11 and Node.js 22.19
  • Implements a React TypeScript frontend with real-time chat interface and typing indicators
  • Creates a FastAPI backend with WebSocket support for streaming AI responses from LM Studio

Reviewed Changes

Copilot reviewed 27 out of 32 changed files in this pull request and generated 3 comments.

File Description
.devcontainer/ Complete devcontainer setup with Dockerfile, configuration, and post-create script
frontend/ React TypeScript chat application with Vite build system and component-based architecture
backend/ FastAPI server with WebSocket streaming support for LM Studio integration
README.md Setup instructions for running the application

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

Comment thread frontend/eslint.config.js Outdated
Comment on lines +6 to +10
import { globalIgnores } from 'eslint/config'

export default tseslint.config([
globalIgnores(['dist']),
{
Copy link

Copilot AI Sep 18, 2025

Choose a reason for hiding this comment

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

The import { globalIgnores } from 'eslint/config' is incorrect. ESLint doesn't export a globalIgnores function from 'eslint/config'. This should be removed as globalIgnores is used as a function on line 9 but is being called on the tseslint.config array instead.

Suggested change
import { globalIgnores } from 'eslint/config'
export default tseslint.config([
globalIgnores(['dist']),
{
export default tseslint.config([
{
ignorePatterns: ['dist/'],

Copilot uses AI. Check for mistakes.
Comment thread frontend/src/components/ChatWindow.tsx Outdated
@@ -0,0 +1,17 @@

Copy link

Copilot AI Sep 18, 2025

Choose a reason for hiding this comment

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

[nitpick] Remove the empty line at the beginning of the file to improve code consistency.

Suggested change

Copilot uses AI. Check for mistakes.
Comment thread backend/.gitignore Outdated
@@ -0,0 +1,216 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[codz]
Copy link

Copilot AI Sep 18, 2025

Choose a reason for hiding this comment

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

The file pattern *.py[codz] should be *.py[cod] to correctly match Python bytecode files (.pyc, .pyo, .pyd).

Suggested change
*.py[codz]
*.py[cod]

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor

@chilinh chilinh left a comment

Choose a reason for hiding this comment

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

Should try and run the template repo first to understand the structure/convention and use that as base for config this repo

Comment thread .devcontainer/Dockerfile Outdated
@@ -0,0 +1,7 @@
FROM mcr.microsoft.com/devcontainers/python:3.11
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.

Should use base image as suggestion: mcr.microsoft.com/devcontainers/base:bookworm

Comment thread .devcontainer/Dockerfile Outdated
WORKDIR /workspace

# Install Node.js and npm
RUN sudo apt-get update && sudo apt-get install -y nodejs npm No newline at end of file
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.

Please use devcontainer features config to setup nodejs and python as mentioned here

Comment thread .devcontainer/devcontainer.json Outdated
],
"features": {
"ghcr.io/devcontainers/features/node:1": {
"version": "22.19"
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.

Should use nodejs lts version for stability

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.

Will be better if we setup this file as in template repo, only need to add node feature and some settings for linting/formating js files

Comment thread backend/requirements.txt Outdated
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.

Consider to use poetry as package manager for fastapi project, it likes npm/yarn for nodejs project

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants