#Am I right that dev team officially

1 messages · Page 1 of 1 (latest)

supple lodge
#

While the VSCode plugin is the only one (I believe) that is not open sourced (i.e. all the others we accept community contributions), we do actively maintain and contribute to almost all of the other ones (most notably JetBrains and Visual Studio).

@lone thorn may be able to provide more details here.

fiery harbor
#

I am asking because I see on videos that VSCode has a lot of functionality, that I am unable to find in some other plugins. But it is ok. 🙂 But in another hand, if I want to improve "other plugins", add some remaining functionality, I am unable to find any API doc or take a look into API calls from VSCode plugin.

supple lodge
#

We do generally introduce features first to VSCode because it's the most popular IDE (by a large margin) and what we use internally (makes it much easier to develop and iterate on) but we are also bringing other IDEs up to spec as well.

What IDE(s) do you use and what functionality are you missing?

fiery harbor
#

I am using neovim. And I want to try to add Codeium Command functionality. Also I've just added workspaces to Chat, but also have some issues with it (not always added, unable to add hidden folder) and I am missing documentation for AddTrackedWorkspace request. 🙂

#

Also, as I see, we are able to AddWorkspace to Chat, but for Completion request we are able to send other_documents. Is it possible to add workspace for the server? In this case Codeium probably would be able to scan the whole workspace to improve suggestions, not only open buffers. Like LSP is doing as I understand. Or it's already working in this way and AddWorkspace request works not only for Chat?

supple lodge
fiery harbor
#

Thanks you! I guess it's all what I need

supple lodge
#

Let us know if you need any additional guidance, thanks for helping to contribute!

fiery harbor
#

Hello,
For working with chat.
We need to send our messages to ChatServer, and receive responses from ChatClient ports? And we need to have websocket(?) connected to Client to receive all messages as stream?

Because finally I am able to send some messages to ChatServer from Neovim plugin, but I am receiving "Healthy" as response 🙂

supple lodge
#

Getting someone from the team more knowledge about the exact interface to help.

fiery harbor
lone thorn
#

Hey trush, we gave this some thought and to be honest we don't think it would be super helpful to provide this interface—I know Neovim users want a native-chat interface to use, but at the pace that we're adding features to our existing browser-based solution, any native interface would struggle to maintain feature parity, and we don't want our users stuck without these new features

fiery harbor
#

Okay, thank you for the response.

I am in progress of implementing PR for Neovim https://github.com/Exafunction/codeium.nvim/pull/180 that implements Code Actions like "Explain", "Add docstring", etc.
Since you are supporting only Web Chat right now and do not have any plans to implement native response (LSP Code Actions btw), is it a way to receive responses in web chat?

Use case:

  1. In Neovim I am able to open Codeium Chat in browser.
  2. I am able to send some commands to Chat server ("Please explain me function A")
  3. Could Codeium responde in Chat from point 1? Should I send some kind of <id> to tell Codeium where it should responde?
GitHub

Start adding chat actions functionality.
Already able to send GenerateCode prompt, but unable to receive response yet (need to find how to receive chat response).
TODO:

P0: Receive response from...

lone thorn
#

You should be able to send a request to the Chat server and receive a response in the chat web client in the browser

#

here's some reference code from our open source jetbrains plugin

fiery harbor
#

hm. Looks like binary messages should be sent to ws://127.0.0.1:<chatServerPort>/connect/ide but I've sent POST requests to http instead. I'll try to play with WebSocket, maybe I will have some progress with it.

#

Thank you for the help

#

Bwt, this is message example that I am sending: {"GetChatMessage": {"chat_message": {"in_progress": false, "source": "CHAT_MESSAGE_SOURCE_USER", "conversation_id": "6l3uiw085A5BhDoLOYRpCVJ2RVyi0yn8", "timestamp": 1714679766, "message_id": "user-1714679766", "content": {"indent": {"code_block_explain": {"file_path": "/home/aliaksandr/Projects/web-service-gin/main.go", "language": 9, "code_block_info": {"raw_source": "", "start_col": 0, "end_line": 0, "end_col": 0, "start_line": 0}}}}}, "metadata": {"request_id": 73, "ide_name": "neovim", "extension_name": "neovim", "api_key": "5cf09402-0460-47cc-a015-7d519fa37bb0", "extension_version": "1.8.30", "ide_version": "0.9.5"}}}

#

Just in case if you are interested 😇

lone thorn
#

i think that looks good

fiery harbor
#

This message does not work for me. Going to investigate deeper. Thank you anyway 🙂

fiery harbor
#

Receiving error on server logs:
E0504 23:30:17.785258 1108311 wire_format.go:24] Error unmarshalling request: proto: cannot parse invalid wire-format data
E0504 23:30:17.785309 1108311 web_server.go:166] ParseRequest error: proto: cannot parse invalid wire-format data
For request:
{"get_chat_message_request": {"chat_message": {"in_progress": false, "source": "CHAT_MESSAGE_SOURCE_USER", "indent": {"explain_function": {"language": 20, "file_path": "/home/user/Projects/CodeiumJetBrains/src/main/kotlin/com/codeium/intellij/chat_server_client/ChatServerClient.kt", "function_info": {"definitionLine": 45, "cleanFunction": "fun getClientUrl(): String {\n return "http://127.0.0.1:${languageServerService.chatClientPort}"\n}", "rawSource": "/** Get the full http:// URL for the chat client. */\nfun getClientUrl(): String {\n return "http://127.0.0.1:${languageServerService.chatClientPort}"\n}", "language": "LANGUAGE_KOTLIN", "leadingWhitespace": " ", "startLine": 44, "params": "()", "startCol": 2, "docstring": "Get the full http:// URL for the chat client. */", "nodeName": "getClientUrl", "endCol": 3, "endLine": 47}}}, "conversation_id": "l5xMoayMvmLRbB7yO6dSc4i6DeLt3EbS", "timestamp": {"nanos": 1.233246e10, "seconds": 1714858569}, "message_id": "user-12332463000"}, "metadata": {"extension_name": "neovim", "ide_name": "neovim", "request_id": 79, "api_key": "5cf09402-0460-47cc-a015-7d519fa37bb0", "extension_version": "1.8.25", "ide_version": "0.9.5"}}}

Could somebody take a look and say if this message is correct? 🥺 Because I am a bit stacked.

lone thorn
#

i think you said indent instead of intent

fiery harbor
#

Updated by error message the same ☹️

lone thorn
#

Can you paste the request but formatted between back tics

#
like this
#

or if you have the curl command that you are trying to send

fiery harbor
#
{
  "get_chat_message_request": {
    "chat_message": {
      "in_progress": false,
      "source": "CHAT_MESSAGE_SOURCE_USER",
      "intent": {
        "generate_code": {
          "line_number": 26,
          "file_path": "/home/user/Projects/CodeiumJetBrains/src/main/kotlin/com/codeium/intellij/chat_server_client/ChatServerClient.kt",
          "language": 20,
          "instruction": "add test"
        }
      },
      "conversation_id": "TVnyzVjCeq7M3K4P70WKOqHDAwPOfxza",
      "timestamp": {
        "nanos": 2896975000,
        "seconds": 1715066955
      },
      "message_id": "user-2896975000"
    },
    "metadata": {
      "extension_name": "neovim",
      "ide_name": "neovim",
      "request_id": 8,
      "api_key": "5cf09402-0460-47cc-a015-7d519fa37bb0",
      "extension_version": "1.8.25",
      "ide_version": "0.9.5"
    }
  }
}
#

This request I've tryied today. It contains less data

fiery harbor
lone thorn
#

can you try this:

{
  "get_chat_message_request": {
    "chat_messages": [{
      "in_progress": false,
      "source": "CHAT_MESSAGE_SOURCE_USER",
      "intent": {
        "generate_code": {
          "line_number": 26,
          "file_path": "/home/user/Projects/CodeiumJetBrains/src/main/kotlin/com/codeium/intellij/chat_server_client/ChatServerClient.kt",
          "language": 20,
          "instruction": "add test"
        }
      },
      "conversation_id": "TVnyzVjCeq7M3K4P70WKOqHDAwPOfxza",
      "timestamp": {
        "nanos": 2896975000,
        "seconds": 1715066955
      },
      "message_id": "user-2896975000"
    }],
    "metadata": {
      "extension_name": "neovim",
      "ide_name": "neovim",
      "request_id": 8,
      "api_key": "5cf09402-0460-47cc-a015-7d519fa37bb0",
      "extension_version": "1.8.25",
      "ide_version": "0.9.5"
    }
  }
}
fiery harbor
#

Unfortunately the same errors in logs.

lone thorn
#

ok i want to figure this out today

#

can i ask how you are testing this

fiery harbor
#
  1. Running codeium language server mannualy to be able to take a look into server logs
  2. In api.lua file Server:start() method need to comment out job:start() line and instead of self.port = find_port(...) just hardcode port value from step one (usually it's self.port = 42100)
  3. In neovim open some project and run command !lua require("codeium").connect_ide() - this command will connect to codeium chat server
  4. !lua require("codeium").generate_code() for example will send message via websocket
  5. In :messages some logs will be printed
fiery harbor
#

Hello again. Just to clarify /connect/ide accespts json or binary proto message?