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

feat: Feature/arm64 fastembed #8

Open
wants to merge 52 commits into
base: develop
Choose a base branch
from

Conversation

jmikedupont2
Copy link
Member

Relates to

Risks

Background

What does this PR do?

What kind of change is this?

Documentation changes needed?

Testing

Where should a reviewer start?

Detailed testing steps

mike dupont and others added 30 commits January 10, 2025 17:52
parent c9d4411
author mike dupont <[email protected]> 1736342650 -0500
committer mike dupont <[email protected]> 1736549491 -0500

rebase and squash

parent 1d5d74a
author mike dupont <[email protected]> 1736342650 -0500
committer mike dupont <[email protected]> 1736435015 -0500

parent 1d5d74a
author mike dupont <[email protected]> 1736342650 -0500
committer mike dupont <[email protected]> 1736435001 -0500

starting on the slimdown

now it is building

lint fix

Update pnpm-lockfile-check.yml

Update pr.yaml

Update integrationTests.yaml

Update image.yaml

Update image.yaml

Update pnpm-lockfile-check.yml

Update smoke-tests.yml

Update greetings.yml

Update image.yaml

Update image.yaml

removing new packages

adding docker hub

update

switching to our org

now running locally
conditions:
1. the volume has to be new
2. the mount has to be correct
3. docker populates the new volume with the existing data.
@jmikedupont2 jmikedupont2 force-pushed the feature/arm64_fastembed branch from 6f79bd2 to 5ad19ab Compare January 14, 2025 17:47
@jmikedupont2 jmikedupont2 changed the title Feature/arm64 fastembed feat: Feature/arm64 fastembed Jan 22, 2025
@jmikedupont2
Copy link
Member Author

It looks like you're working with Docker to pull and run a container for a project related to an agent named "Eliza" and you're using Amazon ECR (Elastic Container Registry) to store the Docker images. You're also trying to set up a bind mount and debug the Docker container using strace.

Here's a breakdown of what's happening in the commands you provided:

  1. Pull the Docker image:

    /usr/bin/docker pull 767503528736.dkr.ecr.us-east-2.amazonaws.com/agent/eliza:feature-arm64_fastembed

    This pulls the Docker image from the AWS Elastic Container Registry (ECR) for the eliza agent.

  2. Run Docker container with specific environment and entrypoint:

    /usr/bin/docker run -p 3000:3000 --mount type=bind,source=/opt/agent,target=/opt/agent --env-file /var/run/agent/secrets/env --rm --name "agent-docker.service" --entry-point docker-entrypoint-strace.sh 767503528736.dkr.ecr.us-east-2.amazonaws.com/agent/eliza:feature-arm64_fastembed pnpm start:debug --characters=characters/eliza.character.json
    • This runs the Docker container, exposing port 3000.
    • It mounts /opt/agent on the host to /opt/agent in the container.
    • It uses an environment file /var/run/agent/secrets/env to set environment variables in the container.
    • The container uses docker-entrypoint-strace.sh as the entrypoint, and it starts the app in debug mode with the Eliza character configuration.
  3. Run a script inside the container to install strace:

    /usr/bin/docker run -p 3000:3000 --mount type=bind,source=/opt/agent,target=/opt/agent --env-file /var/run/agent/secrets/env --rm --name "agent-docker.service" --entrypoint /opt/agent/docker-entrypoint-none.sh 767503528736.dkr.ecr.us-east-2.amazonaws.com/agent/eliza:feature-arm64_fastembed /opt/agent/runlocaldocker-install-script.sh
    • This command runs a script inside the container that installs strace (to debug system calls in the container).
  4. Create a new image with strace installed:

    /usr/bin/docker commit "agent-docker.service" "agent-docker-strace"
    • After running the installation script, this command creates a new Docker image with the name agent-docker-strace.
  5. Debug with strace:

    • The next command appears to run the container using the strace entrypoint for debugging.
    • You mount a tokenizer volume and bind it to the necessary directories inside the container to ensure the correct node modules are available.
  6. Mount tokenizer volume:

    docker run -v tokenizer:/node_modules/tokenizers/ 767503528736.dkr.ecr.us-east-2.amazonaws.com/nodemodules/tokenizer:latest
    • This command mounts a tokenizer volume to the container's /node_modules/tokenizers/ directory.
  7. Final command to bind tokenizer and debug:

    /usr/bin/docker run -p 3000:3000 -v tokenizer:/app/node_modules/@anush008/tokenizers/ -v tokenizer:/app/node_modules/fastembed/node_modules/.pnpm/@anush008+tokenizers@https+++codeload.github.com+meta-introspector+arm64-tokenizers+tar.gz+98_s2457qj3pe4ojcbckddasgzfvu/node_modules/@anush008/ --mount type=bind,source=/opt/agent,target=/opt/agent --env-file /var/run/agent/secrets/env --rm --name "agent-docker.service" --entrypoint /opt/agent/docker-entrypoint-strace2.sh 767503528736.dkr.ecr.us-east-2.amazonaws.com/agent/eliza:feature-arm64_fastembed
    • This runs the Eliza container again with additional tokenizer volume mounts and uses the strace entrypoint (docker-entrypoint-strace2.sh) to enable debugging with system call tracing.

Observations and Suggestions:

  • You seem to be debugging and troubleshooting the container, especially around node module dependencies (tokenizers and fastembed).
  • Ensure that the tokenizer volume is properly created and accessible when binding it into the container.
  • Make sure that all the required node modules are correctly linked and accessible in the container to avoid any missing dependencies.
  • The use of strace will help trace any system calls made by the application, but it might slow down the container. You may want to limit strace to specific areas of the application that need debugging.
  • Consider checking the logs for any specific errors related to volume mounting, environment variables, or missing dependencies.

If you have any specific issues with this setup or need help with debugging, feel free to share more details.

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.

1 participant