caarleexx commited on
Commit
4b105ea
·
verified ·
1 Parent(s): 8eeaf74

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -83
app.py CHANGED
@@ -26,11 +26,7 @@ app = Flask(__name__)
26
  PAYLOAD_BUSCA_BASE = {
27
  "query": {
28
  "function_score": {
29
- "functions": [
30
- {"exp": {"julgamento_data": {"origin": "now", "scale": "47450d", "offset": "1095d", "decay": 0.1}}},
31
- {"filter": {"term": {"orgao_julgador.keyword": "Tribunal Pleno"}}, "weight": 1.15},
32
- {"filter": {"term": {"is_repercussao_geral": True}}, "weight": 1.1}
33
- ],
34
  "query": {
35
  "bool": {
36
  "filter": [
@@ -236,84 +232,8 @@ PAYLOAD_BUSCA_BASE = {
236
  }
237
  }
238
  },
239
- "is_repercussao_geral_agg": {
240
- "filters": {
241
- "filters": {
242
- "true": {
243
- "bool": {
244
- "must": [
245
- {"match": {"is_repercussao_geral": True}},
246
- {"term": {"base": "acordaos"}}
247
- ]
248
- }
249
- },
250
- "false": {
251
- "bool": {
252
- "must": [
253
- {"match": {"is_repercussao_geral": False}},
254
- {"term": {"base": "acordaos"}}
255
- ]
256
- }
257
- }
258
- }
259
- }
260
- },
261
- "is_repercussao_geral_admissibilidade_agg": {
262
- "filters": {
263
- "filters": {
264
- "true": {"match": {"is_repercussao_geral_admissibilidade": True}},
265
- "false": {"match": {"is_repercussao_geral_admissibilidade": False}}
266
- }
267
- }
268
- },
269
- "is_repercussao_geral_merito_agg": {
270
- "filters": {
271
- "filters": {
272
- "true": {"match": {"is_repercussao_geral_merito": True}},
273
- "false": {"match": {"is_repercussao_geral_merito": False}}
274
- }
275
- }
276
- },
277
- "is_repercussao_geral_recurso_interno_agg": {
278
- "filters": {
279
- "filters": {
280
- "true": {"match": {"is_repercussao_geral_recurso_interno": True}},
281
- "false": {"match": {"is_repercussao_geral_recurso_interno": False}}
282
- }
283
- }
284
- },
285
- "is_questao_ordem_agg": {
286
- "filters": {
287
- "filters": {
288
- "true": {"match": {"is_questao_ordem": True}},
289
- "false": {"match": {"is_questao_ordem": False}}
290
- }
291
- }
292
- },
293
- "is_colac_agg": {
294
- "filters": {
295
- "filters": {
296
- "true": {"match": {"is_colac": True}},
297
- "false": {"match": {"is_colac": False}}
298
- }
299
- }
300
- },
301
- "orgao_julgador_agg": {
302
- "aggs": {
303
- "orgao_julgador_agg": {
304
- "terms": {"field": "orgao_julgador.keyword", "size": 200, "execution_hint": "map"}
305
- }
306
- },
307
- "filter": {"bool": {"must": [{"term": {"base": "acordaos"}}]}}
308
- },
309
- "ministro_facet_agg": {
310
- "aggs": {
311
- "ministro_facet_agg": {
312
- "terms": {"field": "ministro_facet.keyword", "size": 200, "execution_hint": "map"}
313
- }
314
- },
315
- "filter": {"bool": {"must": [{"term": {"base": "acordaos"}}]}}
316
- },
317
  "processo_classe_processual_unificada_classe_sigla_agg": {
318
  "aggs": {
319
  "processo_classe_processual_unificada_classe_sigla_agg": {
 
26
  PAYLOAD_BUSCA_BASE = {
27
  "query": {
28
  "function_score": {
29
+
 
 
 
 
30
  "query": {
31
  "bool": {
32
  "filter": [
 
232
  }
233
  }
234
  },
235
+
236
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
237
  "processo_classe_processual_unificada_classe_sigla_agg": {
238
  "aggs": {
239
  "processo_classe_processual_unificada_classe_sigla_agg": {