gptr

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 7, 2025 License: MIT Imports: 8 Imported by: 0

README

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Dockerfile []byte
View Source
var ReportTypes = map[string]string{
	"research_report": "Summary - Short and fast (~2 min)",
	"detailed_report": "Detailed - In depth and longer (~5 min)",
	"resource_report": "Resource Report",
	"outline_report":  "Outline Report",
	"custom_report":   "Custom Report",
	"subtopic_report": "Subtopic Report",
}
View Source
var Tones = map[string]string{
	"objective":   "Impartial and unbiased presentation",
	"formal":      "Academic standards with sophisticated language",
	"analytical":  "Critical evaluation and examination",
	"persuasive":  "Convincing viewpoint",
	"informative": "Clear and comprehensive information",
	"explanatory": "Clarifying complex concepts",
	"descriptive": "Detailed depiction",
	"critical":    "Judging validity and relevance",
	"comparative": "Juxtaposing different theories",
	"speculative": "Exploring hypotheses",
	"reflective":  "Personal insights",
	"narrative":   "Story-based presentation",
	"humorous":    "Light-hearted and engaging",
	"optimistic":  "Highlighting positive aspects",
	"pessimistic": "Focusing on challenges",
}

Functions

func BuildImage

func BuildImage(ctx context.Context) error

BuildImage builds the GPT Researcher Docker image

func GenerateReport

func GenerateReport(ctx context.Context, reportType, tone, input string, out string) error

func RunContainer

func RunContainer(ctx context.Context, reportType, tone, query string, outDir string) error

func SplitSub

func SplitSub(s string) (string, string)

Types

type GptrQuery

type GptrQuery struct {
	Query      string `json:"query"`
	ReportType string `json:"report_type"`
	Tone       string `json:"tone"`
}

type ReportArgs

type ReportArgs struct {
	ReportType string `json:"report_type"`
	Tone       string `json:"tone"`
}

func ToReportArgs

func ToReportArgs(sub string) *ReportArgs

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL