MCPcopy Create free account

hub / github.com/HendrikStrobelt/detecting-fake-text / functions

Functions91 in github.com/HendrikStrobelt/detecting-fake-text

↓ 7 callersFunctionrange
(end)
client/src/ts/etc/Util.ts:25
↓ 3 callersMethodcheck_probabilities
(self, in_text, topk=40)
backend/api.py:81
↓ 3 callersFunctionre_layout
(w = window.innerWidth, h = window.innerHeight)
client/src/ts/start.ts:275
↓ 2 callersMethod_render
(rd: BarChartData)
client/src/ts/vis/BarChart.ts:49
↓ 2 callersFunctioncurrentColorThresholds
()
client/src/ts/start.ts:59
↓ 2 callersMethodgroup
(parent, classes, pos = {x: 0, y: 0})
client/src/ts/etc/SVGplus.ts:11
↓ 2 callersFunctionload_demo
client/src/ts/start.ts:96
↓ 2 callersMethodpostprocess
(self, token)
backend/api.py:156
↓ 2 callersMethodpostprocess
(self, token)
backend/api.py:297
↓ 2 callersFunctionstartSystem
()
client/src/ts/start.ts:84
↓ 2 callersFunctiontoken_cleanup
(token)
client/src/ts/etc/Util.ts:68
↓ 2 callersMethodtrigger
(eventName: string, detail: object)
client/src/ts/etc/SimpleEventHandler.ts:26
↓ 2 callersFunctionupdateTopKstat
()
client/src/ts/start.ts:138
↓ 2 callersMethodurlString
* Generates an URL string from a map of url parameters * @param {{}} urlParameters - the map of parameters * @returns {string} - an URI stri
client/src/ts/etc/URLHandler.ts:71
↓ 1 callersMethod__init__
(self, model_name_or_path="gpt2")
backend/api.py:72
↓ 1 callersMethod_init
()
client/src/ts/vis/Histogram.ts:32
↓ 1 callersMethod_init
()
client/src/ts/vis/ToolTip.ts:16
↓ 1 callersMethod_init
()
client/src/ts/vis/GLTR_Text_Box.ts:45
↓ 1 callersMethod_init
()
client/src/ts/vis/BarChart.ts:33
↓ 1 callersMethod_render
(rd: AnalyzedText = this.renderData)
client/src/ts/vis/GLTR_Text_Box.ts:51
↓ 1 callersMethod_wrangle
(data: BarChartData)
client/src/ts/vis/BarChart.ts:45
↓ 1 callersMethodall_projects
()
client/src/ts/api/GLTR_API.ts:31
↓ 1 callersMethodanalyze
(project: string, text: string, bitmask: number[] = null)
client/src/ts/api/GLTR_API.ts:36
↓ 1 callersMethodbasicURL
()
client/src/ts/etc/URLHandler.ts:7
↓ 1 callersMethodbind
(eventNames: string, eventFunction: Function)
client/src/ts/etc/SimpleEventHandler.ts:14
↓ 1 callersFunctioncleanSpecials
client/src/ts/etc/Util.ts:85
↓ 1 callersFunctioncurrentMode
()
client/src/ts/start.ts:69
↓ 1 callersFunctionflatten
(arr)
client/src/ts/etc/Util.ts:62
↓ 1 callersFunctionmain
()
backend/api.py:314
↓ 1 callersFunctionrun
(model_name_or_path)
preload_gpt2.py:5
↓ 1 callersMethodsample_unconditional
Sample `length` words from the model. Code strongly inspired by https://github.com/huggingface/pytorch-pretrained-BERT/blob/m
backend/api.py:126
↓ 1 callersFunctionsetup_ui
()
client/src/ts/start.ts:247
↓ 1 callersMethodsimpleUId
({prefix = ''})
client/src/ts/etc/Util.ts:9
↓ 1 callersFunctiontop_k_logits
Filters logits to only the top k choices from https://github.com/huggingface/pytorch-pretrained-BERT/blob/master/examples/run_gpt2.py
backend/api.py:56
↓ 1 callersMethodtranslate
({x, y})
client/src/ts/etc/SVGplus.ts:7
↓ 1 callersFunctiontraverseList
(list, splitter, index)
client/src/ts/etc/Util.ts:53
↓ 1 callersMethodupdateData
(ri: GLTR_RenderItem)
client/src/ts/vis/ToolTip.ts:32
↓ 1 callersFunctionupdateEntropyStat
(data: AnalyzeResponse)
client/src/ts/start.ts:144
↓ 1 callersFunctionupdateFromRequest
(data: AnalyzeResponse)
client/src/ts/start.ts:165
↓ 1 callersMethodupdateThresholdValues
(ths: number[])
client/src/ts/vis/GLTR_Text_Box.ts:120
↓ 1 callersMethodupdateUrl
(urlParameters: object, addToBrowserHistory = true)
client/src/ts/etc/URLHandler.ts:109
Method__init__
(self, LM, config)
server.py:22
Method__init__
In the subclass, you need to load all necessary components for the other functions. Typically, this will comprise a tokenizer
backend/api.py:18
Method__init__
(self, model_name_or_path="bert-base-cased")
backend/api.py:184
Method_render
(rD: HistogramData)
client/src/ts/vis/Histogram.ts:53
Method_wrangle
(data)
client/src/ts/vis/Histogram.ts:125
Method_wrangle
(data: AnalyzedText)
client/src/ts/vis/GLTR_Text_Box.ts:112
MethodadjustWidth
(bandH: number)
client/src/ts/vis/Histogram.ts:74
MethodadjustWidth
(bandH: number)
client/src/ts/vis/BarChart.ts:59
Functionanalyze
(analyze_request)
server.py:34
Functionargsort
(array, sortFct)
client/src/ts/etc/Util.ts:18
Functionarr_to_obj
(arr:any)
client/src/ts/etc/Util.ts:36
Methodcheck_probabilities
Function that GLTR interacts with to check the probabilities of words Params: - in_text: str -- The text that you want to ch
backend/api.py:27
Methodcheck_probabilities
Same behavior as GPT-2 Extra param: max_context controls how many words should be fed in left and right Speeds up inf
backend/api.py:200
MethodcolorStats
()
client/src/ts/vis/GLTR_Text_Box.ts:126
MethodcolorValue
(index: number)
client/src/ts/vis/BarChart.ts:62
Methodcoloring
(d: GLTR_RenderItem)
client/src/ts/vis/GLTR_Text_Box.ts:68
Functionconstructor
* Simple constructor. Subclasses should call @superInit(options) as well. * see why here: https://stackoverflow.com/questions/43595943/why-are-de
client/src/ts/vis/VisComponent.ts:69
Methodconstructor
(baseElement, classes = '')
client/src/ts/etc/SVGplus.ts:24
Methodconstructor
(element: Element)
client/src/ts/etc/SimpleEventHandler.ts:9
Methodconstructor
(d3Parent: D3Sel, eventHandler?: SimpleEventHandler, options: {} = {})
client/src/ts/vis/Histogram.ts:26
Methodconstructor
(private parent: D3Sel, private eh: SimpleEventHandler)
client/src/ts/vis/ToolTip.ts:11
Methodconstructor
(parent: D3Sel, eventHandler?: SimpleEventHandler, options = {})
client/src/ts/vis/GLTR_Text_Box.ts:38
Methodconstructor
(parent: D3Sel, eventHandler?: SimpleEventHandler, options = {})
client/src/ts/vis/BarChart.ts:27
Methodconstructor
(private baseURL: string = null)
client/src/ts/api/GLTR_API.ts:24
Functiondecorator
(cls)
backend/class_register.py:5
Functiondestroy
()
client/src/ts/vis/VisComponent.ts:225
MethodeventFunctionWrap
client/src/ts/etc/SimpleEventHandler.ts:17
MethodgetListeners
()
client/src/ts/etc/SimpleEventHandler.ts:22
Functionget_all_projects
()
server.py:27
FunctionhideView
()
client/src/ts/vis/VisComponent.ts:200
MethodisFloat
client/src/ts/etc/URLHandler.ts:26
MethodisInt
client/src/ts/etc/URLHandler.ts:25
Functionobj_to_arr
(obj:object)
client/src/ts/etc/Util.ts:29
Methodparameters
* Read all URL parameters into a map. * @returns {Map} the url parameters as a key-value store (ES6 map)
client/src/ts/etc/URLHandler.ts:17
Methodpostprocess
clean up the tokens from any special chars and encode leading space by UTF-8 code '\u0120', linebreak with UTF-8 code 266 '\u010A'
backend/api.py:46
Functionredir
()
server.py:55
Functionregister_api
(name)
backend/class_register.py:4
Functionsend_data
serves all files from the data dir to ``/data/<path:path>`` :param path: path from api call
server.py:69
Functionsend_static
serves all files from ./client/ to ``/client/<path:path>`` :param path: path from api call
server.py:60
FunctionsetHideElement
(hE: D3Sel)
client/src/ts/vis/VisComponent.ts:196
FunctionsplitString
(string, splitters)
client/src/ts/etc/Util.ts:45
FunctionsuperInitHTML
(options: {} = {})
client/src/ts/vis/VisComponent.ts:92
FunctionsuperInitSVG
* Has to be called as last call in subclass constructor. * @param {{}} options * @param defaultLayers -- create the default <g> layers: bg -
client/src/ts/vis/VisComponent.ts:105
MethodtextLength
(text, style = null)
client/src/ts/etc/SVGplus.ts:30
MethodtypeCast
client/src/ts/etc/URLHandler.ts:28
FunctionunhideView
()
client/src/ts/vis/VisComponent.ts:211
Functionupdate
* Every time data has changed, update is called and * triggers wrangling and re-rendering * @param {Object} data data object * @return
client/src/ts/vis/VisComponent.ts:153
FunctionupdateOptions
* Updates instance options * @param {Object} options only the options that should be updated * @param {Boolean} reRender if option change re
client/src/ts/vis/VisComponent.ts:187
MethodupdateURLParam
(key: string, value: string | any[], addToBrowserHistory = true)
client/src/ts/etc/URLHandler.ts:92
Methodvisility
(vis: boolean)
client/src/ts/vis/ToolTip.ts:23