This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @app.route('/ingest', methods=['POST']) | |
| def ingest(): | |
| files = request.files.getlist('file') | |
| results = [] | |
| for f in files: | |
| filename = f.filename | |
| # Read the file content as bytes for Ragie | |
| file_content = f.read() | |
| response = ragie.documents.create(request={ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| | Column | Column | Column | | |
| | ------ | ------ | ------ | | |
| | | | | | |
| | | | | | |
| | | | | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function generateFibonacciSeries(n) { | |
| let series = [0, 1]; | |
| for (let i = 2; i < n; i++) { | |
| series[i] = series[i - 1] + series[i - 2]; | |
| } | |
| return series; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function generateFibonacciSeries(n) { | |
| const series = [0, 1]; | |
| for (let i = 2; i < n; i++) { | |
| series[i] = series[i - 1] + series[i - 2]; | |
| } | |
| return series; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Model | Overall Accuracy [%] | F_1 Score [%] | |
|---|---|---|---|
| No filtering/no masking | 92.8 | 92.6 | |
| No filtering/with masking | 94.2 | 93.9 | |
| With filtering/no masking | 94.0 | 93.8 | |
| With filtering/with masking | 94.4 | 94.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| | Column | Column | Column | | |
| | ------ | ------ | ------ | | |
| | | | | | |
| | | | | | |
| | | | | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const s3 = require('./config'); | |
| const bucketName = 'my-unique-bucket-name'; | |
| const params = { | |
| Bucket: bucketName | |
| }; | |
| s3.listObjects(params, (error, data) => { | |
| if (error) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const s3 = require('./config'); | |
| const bucketName = 'my-unique-bucket-name'; | |
| const filePath = './downloaded-file.jpg'; | |
| const params = { | |
| Bucket: bucketName, | |
| Key: 'file.jpg' | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const s3 = require('./config'); | |
| const bucketName = 'my-unique-bucket-name'; | |
| const filePath = './path/to/file.jpg'; | |
| const fileContent = fs.readFileSync(filePath); | |
| const params = { | |
| Bucket: bucketName, | |
| Key: 'file.jpg', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const s3 = require('./config'); | |
| const bucketName = 'my-unique-bucket-name'; | |
| s3.createBucket({ Bucket: bucketName }, (error, data) => { | |
| if (error) { | |
| console.error(error); | |
| } else { | |
| console.log(`Bucket ${bucketName} created successfully!`); | |
| } |
NewerOlder