This commit is contained in:
14
packages/reffuse/.code-narrator/gpt_questions/README.liquid
Normal file
14
packages/reffuse/.code-narrator/gpt_questions/README.liquid
Normal file
@@ -0,0 +1,14 @@
|
||||
Create a "ReadMe" guide for the project, named "{{ projectName }}".
|
||||
Include the following:
|
||||
Title, Description,
|
||||
Getting Started by installing npm package, how to run it with npx
|
||||
Configuration is optional and will be generated on first run
|
||||
Reporting bugs, repository and homepage
|
||||
Versioning
|
||||
Authors
|
||||
License
|
||||
|
||||
This is the entry file:
|
||||
###
|
||||
{{ entryFileContent }}
|
||||
###
|
||||
@@ -0,0 +1,4 @@
|
||||
Show how developer would add HowTo in config file,
|
||||
args property is used to inject properties into liquid template, any property set in args can be access in liquid template with {{ keyName }}
|
||||
file property appends extracted content of a file to liquid template, using JSONPath or the extract property that uses LLM to extract content from file
|
||||
Developers MUST create a liquid template in .code-narrator/gpt_questions, this template file is used to ask GPT question
|
||||
@@ -0,0 +1,4 @@
|
||||
Give title and short description that this is an overview file for files located in directory
|
||||
Give short description of each file that is provided
|
||||
Add link to each file, link should be the filename
|
||||
|
||||
101
packages/reffuse/code-narrator.config.js
Normal file
101
packages/reffuse/code-narrator.config.js
Normal file
@@ -0,0 +1,101 @@
|
||||
|
||||
const ConfigurationBuilder = require("code-narrator/dist/src/documentation/plugins/builders/Configuration/ConfigurationBuilder");
|
||||
const FilesBuilder = require("code-narrator/dist/src/documentation/plugins/builders/Files/FilesBuilder");
|
||||
const FoldersBuilder = require("code-narrator/dist/src/documentation/plugins/builders/Folders/FoldersBuilder");
|
||||
const UserDefinedBuilder = require("code-narrator/dist/src/documentation/plugins/builders/UserDefined/UserDefinedBuilder");
|
||||
|
||||
/**
|
||||
* You can find the documentation about code-narrator.config.js at
|
||||
* https://github.com/ingig/code-narrator/blob/master/docs/Configuration/code-narrator.config.js.md
|
||||
*
|
||||
* @type {ICodeNarratorConfig}
|
||||
*/
|
||||
const config = {
|
||||
// App specific configuration files. This could be something like project_name.json
|
||||
config_files: [
|
||||
|
||||
],
|
||||
project_file: "package.json",
|
||||
entry_file: "./dist/index.js",
|
||||
cli_file: "",
|
||||
project_path: "./",
|
||||
source_path: "src",
|
||||
documentation_path: "./docs",
|
||||
test_path: "test",
|
||||
exclude: [
|
||||
"/node_modules",
|
||||
".env",
|
||||
"/.idea",
|
||||
"/.git",
|
||||
".gitignore",
|
||||
"/.code-narrator",
|
||||
"/dist",
|
||||
"/build",
|
||||
"package-lock.json",
|
||||
],
|
||||
// Indicates if the documentation should create a README file in root of project
|
||||
readmeRoot: true,
|
||||
// Url to the repository, code-narrator tries to extract this from project file
|
||||
repository_url: "git+https://github.com/Thiladev/reffuse.git",
|
||||
// These are the plugins used when building documentation. You can create your own plugin. Checkout the code-narrator docs HowTo create a builder plugin
|
||||
builderPlugins: [
|
||||
ConfigurationBuilder,
|
||||
FilesBuilder,
|
||||
FoldersBuilder,
|
||||
UserDefinedBuilder,
|
||||
],
|
||||
// These are system commends send to GPT with every query
|
||||
gptSystemCommands: [
|
||||
"Act as a documentation expert for software",
|
||||
"If there is :::note, :::info, :::caution, :::tip, :::danger in the text, extract that from its location and format it correctly",
|
||||
"Return your answer in {DocumentationType} format",
|
||||
"If you notice any secret information, replace it with ***** in your response",
|
||||
],
|
||||
documentation_type: "md",
|
||||
document_file_extension: ".md",
|
||||
folderRootFileName: "README",
|
||||
cache_file: ".code-narrator/cache.json",
|
||||
gptModel: "gpt-4",
|
||||
aiService: undefined,
|
||||
project_name: "reffuse",
|
||||
include: [
|
||||
"src/**/*",
|
||||
],
|
||||
// Array of user defined documentations. See code-narrator How to create a user defined builder
|
||||
builders: [
|
||||
{
|
||||
name: "README",
|
||||
type: "README",
|
||||
template: "README",
|
||||
sidebarPosition: 1,
|
||||
args: {
|
||||
entryFileContent: "content(package.json)",
|
||||
aiService: undefined,
|
||||
},
|
||||
aiService: undefined,
|
||||
},
|
||||
{
|
||||
name: "HowTo Overview",
|
||||
type: "README",
|
||||
template: "overview_readme",
|
||||
path: "howto",
|
||||
files: [
|
||||
{
|
||||
path: "howto/*.md",
|
||||
aiService: undefined,
|
||||
},
|
||||
],
|
||||
pages: [
|
||||
{
|
||||
name: "HowTo Example",
|
||||
type: "howto",
|
||||
template: "howto_create_howto",
|
||||
aiService: undefined,
|
||||
},
|
||||
],
|
||||
aiService: undefined,
|
||||
},
|
||||
],
|
||||
|
||||
}
|
||||
module.exports = config;
|
||||
Reference in New Issue
Block a user