From 96b3f1aa1ce4a4ae736ae4b5c22ba1a8af0d8090 Mon Sep 17 00:00:00 2001 From: cjkfyi <165058376+cjkfyi@users.noreply.github.com> Date: Thu, 4 Apr 2024 23:46:46 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=86=98=20!=3D=20Start=20of=20Shift?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: cjkfyi <165058376+cjkfyi@users.noreply.github.com> --- README.md | 157 ++++++++++++++++++++++++++++++++++++----- extension/package.json | 2 +- package.json | 2 +- 3 files changed, 142 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 94d8726..4d44ab7 100755 --- a/README.md +++ b/README.md @@ -4,26 +4,13 @@ ## ⁉ī¸ -After being fed-up with having to Copy and Paste my code, back-and-forth a million times, for a more current understanding every turn... `gemify` was suddenly born. +After being fed-up with having to Copy and Paste my code, back-and-forth a million times for a more current understanding every turn... `gemify` was suddenly born. -I've noticed some traffic for this repo in the first week of prototyping. Which lead me to start planning ahead some. Expect continuous development and information, eventually an entire community (if possible)? With all of that in-mind, came the realization that many would (or could) try to capitalize on a mere fork of this single, random idea of mine? +After noticing some traffic for this repo in the first week of prototyping, I've decided to focus a bit on documentation. This repo could have been private and monetized. I'm not going to sit here and dream of turning this into some SaaS operation. My goal is to keep this project open-source; preventing commercialization, data-collection and additional bottlenecks. Help a fella out, PRs are always welcomed. -## đŸĨž - -#### Frontend (JS) - -- Custom, and soon to be responsive UI. -- Webview API for integration with VSCode. - -#### Backend (Go) - -- Well-orchestrated H/2 Proxy & gRPC server. -- Utilizing `bitcask` & `bitio` for our storage. -- Custom logger and improved err handling. (🔜â„ĸī¸) - -## 💕 +## 🌱 ### Dev @@ -31,6 +18,8 @@ Help a fella out, PRs are always welcomed. # first, cd somewhere awesome ~ or just ~ git clone git@github.com:cjkfyi/gemify.git cd gemify +# from: aistudio.google.com +echo 'API_KEY="..."' >> .env yarn cd extension yarn @@ -43,4 +32,138 @@ go run ./cmd/main.go ##### Tip: -ℹī¸: Open or Add `extension/` into a VSCode workspace, then hit `F5`. \ No newline at end of file +ℹī¸: Open or Add `extension/` into a VSCode workspace, then hit `F5`. + +## đŸĨž + +#### Backend (Go) + +- Well-orchestrated H/2 Proxy & gRPC server. +- Utilizing `bitcask` & `bitio` for our storage. +- Custom logger and improved err handling. (🔜â„ĸī¸) + +```go +require ( + go-chi/chi v5.0.12 + google/genai v0.10.0 + google/grpc v1.62.1 + google/protobuf v1.33.0 + gorilla/websocket v1.5.1 + joho/godotenv v1.5.1 + prologic/bitcask v2.0.3 +) +``` + +#### Frontend (JS) + +- Custom, and soon to be responsive UI. +- Webview API for integration with VSCode. + +```json + "devDependencies": { + "esbuild": "^0.20.2", + "eslint": "^8.56.0" + }, + "dependencies": { + "ws": "^8.16.0", + "zustand": "^4.5.2" + } +``` + +## 📚 + +### newConvo + +_r.Post("/chat", newConvo)_ + +`POST` @ `127.0.0.1:8000/chat` + +#### Response: + +```json +{ + "command": "execNewConvo", + "status": "success", + "data": { + "convoID": "6e450f653022ae70" + } +} +``` + +--- + +### getConvos + +_r.Get("/chat/list", getConvos)_ + +`GET` @ `127.0.0.1:8000/chat/list` + +#### Response: + +```json +{ + "command": "convoList", + "status": "success", + "data": { + "conversations": [ + { + "id": "6e450f653022ae70", + "title": "VSCode extension `gemify`", + "lastModified": "2024-04-04T23:24:24.160944195-07:00", + "firstCreated": "2024-04-04T23:24:24.160944195-07:00", + }, + { + "id": "34b6a8995d1e1d39", + "title": "Bubbletea TUI app `backstacc`", + "lastModified": "2024-04-04T11:33:17.5810942-07:00", + "firstCreated": "2024-04-04T11:33:17.5810942-07:00", + }, + ] + } +} +``` + +--- + +### newMessage + +_r.Get("/ws/chat/{id}", newMessage)_ + +`WS` @ `ws://127.0.0.1:8000/ws/chat/{convoID}` + +#### Message: + +```json +{ + "message": "MD: List 3 trees, and 2 facts for each of them?" +} +``` + +#### Response: + +``` +> Connection Terminated +23:31:26 + +> {"content":"EOF"} +23:31:26 + +> {"content":" years"} +23:31:26 + +> {"content":"ces maple syrup, a popular sweetener\n* Leaves turn vibrant shades of red, orange, and yellow in the fall\n\n**Tree 3: Redwood Tree**\n* Among the tallest trees in the world, reaching heights of up to 379 feet\n* Can live for over 2,000"} +23:31:26 + +> {"content":"1,000 years\n* Produces acorns, which are a valuable food source for wildlife\n\n**Tree 2: Maple Tree**\n* Produ"} +23:31:25 + +> {"content":"**Tree 1: Oak Tree**\n* Can live for up to "} +23:31:25 + +> { "message": "MD: List 3 trees, and 2 facts for each of them?" } +23:31:24 + +> Connected to ws://localhost:8000/ws/chat/34b6a8995d1e1d39 +23:30:56 +``` + diff --git a/extension/package.json b/extension/package.json index 15d3ce9..57a73d9 100755 --- a/extension/package.json +++ b/extension/package.json @@ -2,7 +2,7 @@ "name": "gemify", "displayName": "Gemify", "description": "Yet another coding assistant đŸŒŦī¸", - "version": "0.6.2", + "version": "0.6.3", "engines": { "vscode": "^1.86.2" }, diff --git a/package.json b/package.json index 93630cf..f2a2e14 100755 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "gemify", "description": "Yet another coding assistant đŸŒŦī¸", - "version": "0.6.2", + "version": "0.6.3", "author": "@cjkfyi", "license": "MIT", "scripts": {