Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pnpm run dev does not work out of the box #780

Closed
lalalune opened this issue Dec 2, 2024 · 3 comments
Closed

pnpm run dev does not work out of the box #780

lalalune opened this issue Dec 2, 2024 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@lalalune
Copy link
Member

lalalune commented Dec 2, 2024

Right now, pnpm run dev is not working properly with turbo.

What we want is for dev to start all packages in watch mode with turbo so that the monorepo can automatically update dependencies downstream while developing, i.e. a watch mode that doesn't require a rebuild.

@fabianhug
Copy link
Member

check this, I've found some type error in the postgres adapter, but am not sure if I mixed up something on my end:

#788

@lalalune

@Hdpbilly
Copy link

Hdpbilly commented Dec 5, 2024

check this, I've found some type error in the postgres adapter, but am not sure if I mixed up something on my end:

#788

@lalalune

I believe it is due to improper usage of the plpgsql function get_embedding_dimension() which is attempting to use dynamic type modifier.

Particularly in the postgres schemaL

CREATE OR REPLACE FUNCTION get_embedding_dimension()
RETURNS INTEGER AS $$
BEGIN
    -- Check for OpenAI first
    IF current_setting('app.use_openai_embedding', TRUE) = 'true' THEN
        RETURN 1536;  -- OpenAI dimension
    -- Then check for Ollama
    ELSIF current_setting('app.use_ollama_embedding', TRUE) = 'true' THEN
        RETURN 1024;  -- Ollama mxbai-embed-large dimension
    ELSE
        RETURN 384;   -- BGE/Other embedding dimension
    END IF;
END;
$$ LANGUAGE plpgsql;

@hamedf62
Copy link

hamedf62 commented Dec 6, 2024

check this, I've found some type error in the postgres adapter, but am not sure if I mixed up something on my end:
#788
@lalalune

I believe it is due to improper usage of the plpgsql function get_embedding_dimension() which is attempting to use dynamic type modifier.

Particularly in the postgres schemaL

CREATE OR REPLACE FUNCTION get_embedding_dimension()
RETURNS INTEGER AS $$
BEGIN
    -- Check for OpenAI first
    IF current_setting('app.use_openai_embedding', TRUE) = 'true' THEN
        RETURN 1536;  -- OpenAI dimension
    -- Then check for Ollama
    ELSIF current_setting('app.use_ollama_embedding', TRUE) = 'true' THEN
        RETURN 1024;  -- Ollama mxbai-embed-large dimension
    ELSE
        RETURN 384;   -- BGE/Other embedding dimension
    END IF;
END;
$$ LANGUAGE plpgsql;

this is the critical issue would be solve as pgsql doesn't accept dynamic modifiers.

as i checked in supabase you have define 3 different memories table for different embedding dimensions, and same required in PostgreSQL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants