git clone -b $(curl -L https://grpc.io/release) https://github.com/grpc/grpc
GRPC_PATH=${PROJECT_PATH}/grpc
cd ${GRPC_PATH}
git submodule update --init
cd third_party/protobuf
./autogen.sh && ./configure && make
sudo make install
sudo ldconfig
export LDFLAGS="$LDFLAGS -lm"
cd ${GRPC_PATH}
make clean
make
sudo make install
sudo ldconfig
cd ${PROJECT_PATH}
git clone https://github.com/googleapis/googleapis.git
cd googleapis/
git checkout 980cdfa
make LANGUAGE=cpp
Make sure you setup environment variable $GOOGLEAPIS_GENS_PATH
Default Assistant gRPC API endpoint is embeddedassistant.googleapis.com. If you want to test with a custom Assistant gRPC API endpoint, you can pass --api_endpoint CUSTOM_API_ENDPOINT.
Enabling screen output
To get a visual output from the Assistant, provide a command to be run alongside every step of the conversation. It will execute that command along along with a provided argument of a temporary HTML file.
echo"what time is it"| ./run_assistant_text --credentials ./credentials.json --html_out google-chrome
After you enter text, it will run google-chrome /tmp/google-assistant-cpp-screen-out.html.
If you prefer a different program, use that argument instead.
请发表评论