Repository doc · gemini/sample-apps/quickbot/document-search-using-agent-builder/frontend/README.md · Open on GitHub · Part of Gemini Notebooks
QuickBotAppFrontend
This project was generated with Angular CLI version 15.1.3.
Development server
Run ng serve for a dev server. Navigate to http://localhost:4200/. The application will automatically reload if you change any of the source files.
Code scaffolding
Run ng generate component component-name to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module.
Build
Run ng build to build the project. The build artifacts will be stored in the dist/ directory.
Run ng e2e to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.
Initialize gts (if not already done in the project):
Navigate to the frontend/ directory and run:
npx gts init
This will set up gts and create necessary configuration files (like tsconfig.json). Ensure your tsconfig.json (or a related gts config file like .gtsrc) includes an extension for gts defaults, typically:
{ "extends": "./node_modules/gts/tsconfig-google.json", // ... other configurations}
Check for linting issues:
npm run lint
(This assumes a lint script is defined in package.json, e.g., "lint": "gts lint")
(This assumes a fix script is defined in package.json, e.g., "fix": "gts fix")
Backend (Python with pylint and black)
Ensure Dependencies are Installed:
Add pylint and black to your backend/requirements.txt file:
pylint
black
Then install them within your virtual environment:
pip install pylint black# or pip install -r requirements.txt
Configure pylint:
It’s recommended to have a .pylintrc file in your backend/ directory to configure pylint rules. You might need to copy a standard one or generate one (pylint --generate-rcfile > .pylintrc).
Check for linting issues with pylint:
Navigate to the backend/ directory and run: