Code Quality Improvement Program
Ensure the reliability of the AI output code by:
- contextual enhancement::
- In the project root directory, place the
.cloudbaserc.json
Declare the type of item - utilization
/// @cloudbase-required
Note Designation of Special Needs
- In the project root directory, place the
- verification mechanism::
- Autorun before deployment
tcb ai validate
Check:- Cloud Function Dependency Integrity
- Database query efficiency
- API Response Format
- Autorun before deployment
- Progressive optimization::
- The first version generates the base implementation code
- follow-up action
优化性能/增加缓存/提高安全性
Iterative improvements such as directives
Best Practice: For business-critical components, it is recommended to generate sample code first, and then pass it through the添加单元测试
The instructions refine the validation logic and finally deploy to a standalone environment for stress testing.
This answer comes from the articleCloudBase AI ToolKit: a toolset to help developers rapidly build and deploy AI applications to the cloudThe