Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/FreedomIntelligence/GrammarGPT
/ functions
Functions
23 in github.com/FreedomIntelligence/GrammarGPT
⨍
Functions
23
◇
Types & classes
3
↓ 3 callers
Method
generate_prompt
( self, instruction: str, input: Union[None, str] = None, label: Union[None, s
utils/prompter.py:28
↓ 2 callers
Method
get_response
(self, output: str)
utils/prompter.py:50
↓ 2 callers
Function
read_file
(file, test=True)
pseudo_data/check_no_overlap.py:6
↓ 2 callers
Function
tokenize
(prompt, add_eos_token=True)
finetune.py:141
↓ 1 callers
Function
check
(construct_file,dev_file,test_file,overlap_file)
pseudo_data/check_no_overlap.py:28
↓ 1 callers
Function
evaluate
( instruction, input=None, # temperature=0.1, temperature=0.7, top_p=0
generate.py:93
↓ 1 callers
Function
generate_with_streaming
(**kwargs)
generate.py:138
↓ 1 callers
Function
load_json
(file)
pseudo_data/check_no_overlap.py:14
↓ 1 callers
Function
main
( use_lora= False, test_file='nacgec.test.input', des_file ='../submission.txt', load_8bit: bo
generate.py:26
↓ 1 callers
Function
overlap_detect
(cons_sent, sent_list)
pseudo_data/check_no_overlap.py:19
Method
__call__
(self, input_ids, scores)
utils/callbacks.py:19
Method
__enter__
(self)
utils/callbacks.py:71
Method
__exit__
(self, exc_type, exc_val, exc_tb)
utils/callbacks.py:74
Method
__init__
(self, callback_func=None)
utils/callbacks.py:16
Method
__init__
(self, func, kwargs={}, callback=None)
utils/callbacks.py:32
Method
__init__
(self, template_name: str = "", verbose: bool = False)
utils/prompter.py:13
Method
__iter__
(self)
utils/callbacks.py:61
Method
__next__
(self)
utils/callbacks.py:64
Method
_callback
(val)
utils/callbacks.py:40
Function
generate_and_tokenize_prompt
(data_point)
finetune.py:163
Function
generate_with_callback
(callback=None, **kwargs)
generate.py:128
Method
gentask
()
utils/callbacks.py:45
Function
train
( use_lora: bool = False, # model/data params base_model: str = "FreedomIntelligence/phoenix-inst-
finetune.py:28