Skip to content

[Inference] Run EIS locally #215475

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

Draft
wants to merge 19 commits into
base: main
Choose a base branch
from
Draft

Conversation

dgieselaar
Copy link
Member

@dgieselaar dgieselaar commented Mar 21, 2025

  1. Run:
    $ AWS_BEDROCK_ACCESS_KEY_ID={accessKeyId} AWS_BEDROCK_SECRET_ACCESS_KEY={secret} AWS_BEDROCK_REGION={region} node scripts/eis.js

2a. After it's started, run ES with:
$ yarn es snapshot --license trial -E xpack.inference.elastic.url=http://localhost:8443
2b. The command will output credentials for a preconfigured EIS connector. Paste it into kibana(.dev).yml.

  1. Start Kibana as usual.

  2. Run:
    yarn run ts-node --transpile-only x-pack/solutions/observability/packages/kbn-genai-cli/recipes/hello_world.ts

This should output:

 ~/dev/kibana  eis-connector-cli *219  yarn run ts-node --transpile-only x-pack/solutions/observability/packages/kbn-genai-cli/recipes/hello_world.ts                                                                       1 ✘  20.18.2 Node  12:53:25 
yarn run v1.22.22
$ /Users/dariogieselaar/dev/kibana/node_modules/.bin/ts-node --transpile-only x-pack/solutions/observability/packages/kbn-genai-cli/recipes/hello_world.ts 
 info Discovered kibana running at: http://elastic:[email protected]:5601/kbn
 info {
        id: 'extract_personal_details',
        content: '',
        output: { name: 'Sarah', age: 29, city: 'San Francisco' }
      }
✨  Done in 5.47s.

@elasticmachine
Copy link
Contributor

elasticmachine commented Mar 21, 2025

🤖 Jobs for this PR can be triggered through checkboxes. 🚧

ℹ️ To trigger the CI, please tick the checkbox below 👇

  • Click to trigger kibana-pull-request for this PR!
  • Click to trigger kibana-deploy-project-from-pr for this PR!
  • Click to trigger kibana-deploy-cloud-from-pr for this PR!

@dgieselaar dgieselaar added release_note:skip Skip the PR/issue when compiling release notes v9.1.0 v8.19.0 labels Mar 30, 2025
@dgieselaar dgieselaar changed the title [Inference] Setup EIS connector if needed [Inference] Run EIS locally Mar 31, 2025
@elasticmachine
Copy link
Contributor

elasticmachine commented Mar 31, 2025

💔 Build Failed

Failed CI Steps

History

@jedrazb
Copy link
Member

jedrazb commented Apr 9, 2025

Hey especially running gateway in docker I found that host.docker.internal is more robust than localhost

That's the magic command to start ES for me (I see you are handling certs here so no need to disable it?)

yarn es serverless --projectType es -E xpack.inference.elastic.url=https://host.docker.internal:8443 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release_note:skip Skip the PR/issue when compiling release notes v8.19.0 v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants