@@ -61,7 +61,40 @@ class Folder_DocumentLoaders implements INode {
61
61
'.csv' : ( path ) => new CSVLoader ( path ) ,
62
62
'.docx' : ( path ) => new DocxLoader ( path ) ,
63
63
// @ts -ignore
64
- '.pdf' : ( path ) => new PDFLoader ( path , { pdfjs : ( ) => import ( 'pdf-parse/lib/pdf.js/v1.10.100/build/pdf.js' ) } )
64
+ '.pdf' : ( path ) => new PDFLoader ( path , { pdfjs : ( ) => import ( 'pdf-parse/lib/pdf.js/v1.10.100/build/pdf.js' ) } ) ,
65
+ '.aspx' : ( path ) => new TextLoader ( path ) ,
66
+ '.asp' : ( path ) => new TextLoader ( path ) ,
67
+ '.cpp' : ( path ) => new TextLoader ( path ) , // C++
68
+ '.c' : ( path ) => new TextLoader ( path ) ,
69
+ '.cs' : ( path ) => new TextLoader ( path ) ,
70
+ '.css' : ( path ) => new TextLoader ( path ) ,
71
+ '.go' : ( path ) => new TextLoader ( path ) , // Go
72
+ '.h' : ( path ) => new TextLoader ( path ) , // C++ Header files
73
+ '.java' : ( path ) => new TextLoader ( path ) , // Java
74
+ '.js' : ( path ) => new TextLoader ( path ) , // JavaScript
75
+ '.less' : ( path ) => new TextLoader ( path ) , // Less files
76
+ '.ts' : ( path ) => new TextLoader ( path ) , // TypeScript
77
+ '.php' : ( path ) => new TextLoader ( path ) , // PHP
78
+ '.proto' : ( path ) => new TextLoader ( path ) , // Protocol Buffers
79
+ '.python' : ( path ) => new TextLoader ( path ) , // Python
80
+ '.py' : ( path ) => new TextLoader ( path ) , // Python
81
+ '.rst' : ( path ) => new TextLoader ( path ) , // reStructuredText
82
+ '.ruby' : ( path ) => new TextLoader ( path ) , // Ruby
83
+ '.rb' : ( path ) => new TextLoader ( path ) , // Ruby
84
+ '.rs' : ( path ) => new TextLoader ( path ) , // Rust
85
+ '.scala' : ( path ) => new TextLoader ( path ) , // Scala
86
+ '.sc' : ( path ) => new TextLoader ( path ) , // Scala
87
+ '.scss' : ( path ) => new TextLoader ( path ) , // Sass
88
+ '.sol' : ( path ) => new TextLoader ( path ) , // Solidity
89
+ '.sql' : ( path ) => new TextLoader ( path ) , //SQL
90
+ '.swift' : ( path ) => new TextLoader ( path ) , // Swift
91
+ '.markdown' : ( path ) => new TextLoader ( path ) , // Markdown
92
+ '.md' : ( path ) => new TextLoader ( path ) , // Markdown
93
+ '.tex' : ( path ) => new TextLoader ( path ) , // LaTeX
94
+ '.ltx' : ( path ) => new TextLoader ( path ) , // LaTeX
95
+ '.html' : ( path ) => new TextLoader ( path ) , // HTML
96
+ '.vb' : ( path ) => new TextLoader ( path ) , // Visual Basic
97
+ '.xml' : ( path ) => new TextLoader ( path ) // XML
65
98
} )
66
99
let docs = [ ]
67
100
0 commit comments