This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| printf "\nConnect to mysql...\n\n" | |
| printf "Using this user: root\n" | |
| printf "Using this password: root-password\n" | |
| # Create a temporary mysql instance using docker, letting the OS chose a port. | |
| container=$(docker run -e MYSQL_ROOT_PASSWORD=root-password -d --rm -p 3306 mysql) | |
| # Print the host port used. | |
| printf "Using this port:\n" | |
| docker container port $container |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { | |
| FileMetadata, | |
| GoogleAIFileManager, | |
| UploadFileResponse, | |
| } from "@google/generative-ai/server"; | |
| // GoogleAIFileManager can't use streams yet, so we need to do it on our own. | |
| // See: https://github.com/google-gemini/generative-ai-js/pull/252 | |
| // Note that this is a direct copy of the existing implementation; it would |
OlderNewer