
텍스트 요약 생성을 위한 최신 기술 모델 비교
레포를 복제하십시오
pip3 install -r requirements.txt
python -m spacy download en_core_web_md from NLTK_summarizer import SummarizerNLTK
print ( SummarizerNLTK (). summary ( text = "" )) from BERT_summarizer import SummarizerBERT
print ( SummarizerBERT (). summary ( text = "" )) from T5_BART_summarizer import SummarizerT5BART
print ( SummarizerT5BART (). summary ( text = "" ))더 나은 이해를 위해 파일의 문서를보십시오.
Kaggle 데이터 세트에서 가져온 : https://www.kaggle.com/snapcrack/all-the-news
WASHINGTON — Congressional Republicans have a new fear when it comes to their health care lawsuit against the Obama administration: They might win. The incoming Trump administration could choose to no longer defend the executive branch against the suit, which challenges the administration’s authority to spend billions of dollars on health insurance subsidies for and Americans, handing House Republicans a big victory on issues. But a sudden loss of the disputed subsidies could conceivably cause the health care program to implode, leaving millions of people without access to health insurance before Republicans have prepared a replacement. That could lead to chaos in the insurance market and spur a political backlash just as Republicans gain full control of the government. To stave off that outcome, Republicans could find themselves in the awkward position of appropriating huge sums to temporarily prop up the Obama health care law, angering conservative voters who have been demanding an end to the law for years. In another twist, Donald J. Trump’s administration, worried about preserving executive branch prerogatives, could choose to fight its Republican allies in the House on some central questions in the dispute. Eager to avoid an ugly political pileup, Republicans on Capitol Hill and the Trump transition team are gaming out how to handle the lawsuit, which, after the election, has been put in limbo until at least late February by the United States Court of Appeals for the District of Columbia Circuit. They are not yet ready to divulge their strategy. “Given that this pending litigation involves the Obama administration and Congress, it would be inappropriate to comment,” said Phillip J. Blando, a spokesman for the Trump transition effort. “Upon taking office, the Trump administration will evaluate this case and all related aspects of the Affordable Care Act. ” In a potentially decision in 2015, Judge Rosemary M. Collyer ruled that House Republicans had the standing to sue the executive branch over a spending dispute and that the Obama administration had been distributing the health insurance subsidies, in violation of the Constitution, without approval from Congress. The Justice Department, confident that Judge Collyer’s decision would be reversed, quickly appealed, and the subsidies have remained in place during the appeal. In successfully seeking a temporary halt in the proceedings after Mr. Trump won, House Republicans last month told the court that they “and the ’s transition team currently are discussing potential options for resolution of this matter, to take effect after the ’s inauguration on Jan. 20, 2017. ” The suspension of the case, House lawyers said, will “provide the and his future administration time to consider whether to continue prosecuting or to otherwise resolve this appeal. ” Republican leadership officials in the House acknowledge the possibility of “cascading effects” if the payments, which have totaled an estimated $13 billion, are suddenly stopped. Insurers that receive the subsidies in exchange for paying costs such as deductibles and for eligible consumers could race to drop coverage since they would be losing money. Over all, the loss of the subsidies could destabilize the entire program and cause a lack of confidence that leads other insurers to seek a quick exit as well. Anticipating that the Trump administration might not be inclined to mount a vigorous fight against the House Republicans given the ’s dim view of the health care law, a team of lawyers this month sought to intervene in the case on behalf of two participants in the health care program. In their request, the lawyers predicted that a deal between House Republicans and the new administration to dismiss or settle the case “will produce devastating consequences for the individuals who receive these reductions, as well as for the nation’s health insurance and health care systems generally. ” No matter what happens, House Republicans say, they want to prevail on two overarching concepts: the congressional power of the purse, and the right of Congress to sue the executive branch if it violates the Constitution regarding that spending power. House Republicans contend that Congress never appropriated the money for the subsidies, as required by the Constitution. In the suit, which was initially championed by John A. Boehner, the House speaker at the time, and later in House committee reports, Republicans asserted that the administration, desperate for the funding, had required the Treasury Department to provide it despite widespread internal skepticism that the spending was proper. The White House said that the spending was a permanent part of the law passed in 2010, and that no annual appropriation was required — even though the administration initially sought one. Just as important to House Republicans, Judge Collyer found that Congress had the standing to sue the White House on this issue — a ruling that many legal experts said was flawed — and they want that precedent to be set to restore congressional leverage over the executive branch. But on spending power and standing, the Trump administration may come under pressure from advocates of presidential authority to fight the House no matter their shared views on health care, since those precedents could have broad repercussions. It is a complicated set of dynamics illustrating how a quick legal victory for the House in the Trump era might come with costs that Republicans never anticipated when they took on the Obama White House.
| 틀 | 모델 | 시간 (다운로드 포함) | 완전한 | 요약 | 시간 (다운로드없이) 시간 |
|---|---|---|---|---|---|
| 1 | NLTK 코퍼스 | 0 | 진실 | 들어오는 트럼프 행정부는 ... | 0 |
| 2 | 베르트-베이스에 배치 된 kmeans | 27 | 진실 | 들어오는 트럼프 행정부는 ... | 15 |
| 3 | 베르트-베이스-배열 GMM | 3 | 진실 | 들어오는 트럼프 행정부는 ... | 4 |
| 4 | Bert-large-uncased kmeans | 29 | 진실 | 들어오는 트럼프 행정부는 ... | 8 |
| 5 | Bert-large-uncased GMM | 9 | 진실 | 법무부, 판사 C ... | 9 |
| 6 | xlnet-base-cased kmeans | 11 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 3 |
| 7 | XLNET-Base-Cased GMM | 3 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 3 |
| 8 | XLM-MLM-ENFR-1024 KMEANS | 20 | 진실 | 워싱턴 --- 의회 공화당은 ... | 4 |
| 9 | XLM-MLM-ENFR-1024 GMM | 25 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 5 |
| 10 | Distilbert-Base에 배치 된 Kmeans | 6 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 2 |
| 11 | Distilbert-base-uncased GMM | 2 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 2 |
| 12 | Albert-Base-V1 Kmeans | 3 | 진실 | 그 결과를 막기 위해 공화당은 ... | 2 |
| 13 | Albert-Base-V1 GMM | 2 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 2 |
| 14 | Albert-Large-V1 Kmeans | 4 | 진실 | 들어오는 트럼프 행정부는 ... | 2 |
| 15 | Albert-Large-V1 GMM | 3 | 진실 | 그러나 분쟁 보조금의 갑작스런 손실은 ... | 3 |
| 16 | Facebook/Bart-Large-CNN | 36 | 거짓 | 오류 | 56 |
| 17 | T5-11B | 4 | 거짓 | 오류 | 2 |
| 18 | T5-3B | 건너 뛰었습니다 | 거짓 | 오류 | 건너 뛰었습니다 |
| 19 | T5-베이스 | 30 | 진실 | 갑자기 손실 | 38 |
| 20 | T5-LARGE | 건너 뛰었습니다 | 거짓 | 오류 | 건너 뛰었습니다 |
| 21 | T5-Small | 9 | 진실 | 들어오는 행정부 | 11 |
출력을 비교하려면 results 폴더로 이동하십시오.
항상 몇 초입니다
건너 뛰면 여러 번 시도한 후에도 실패한 것을 의미합니다
오류는 프로세스가 완료되지 않았 음을 의미합니다
이 코드는 Google Colab (GPU Runtime)에서 실행되었으며 하드웨어가 상당히 우수합니다.
또한 미리 훈련 된 대형 모델을 다운로드하는 데 시간이 걸릴 수 있습니다.
NLTK는 대부분 더 빠르고 더 잘 작동합니다.
다음으로 가장 좋은 것은 Bert이지만 Bert에서 토큰 화가 발생하는 방식은 때로는 모든 의미를 잃어버린 사이에 문장을 남깁니다. 매우 큰 텍스트와 잘 어울립니다.
T5는 새로운 문장을 알아 내려고하지만 괜찮은 하드웨어를 사용해도 실행하는 것은 거의 불가능합니다. T5의 경우 모델의 크기를 선택할 수 있습니다. T5-베이스 위의 모든 것은 GPU 또는 TPU에서도 매우 느립니다.
Facebook Bart는 너무 많은 Computatons를 수행하고 기억을 빠르게 소진합니다.
전체 데이터 세트에서 실행하십시오
PYPI 용 래퍼를 게시하십시오
GPU의 효과를 비교하십시오
Facebook의 바트를 추가하십시오
Google T5를 추가하십시오
Bert를 크게 추가하십시오
나에게 작은 것을 줄 수 있습니까? Dopmaine? 이 프로젝트를 주연시켜 지원합니다
Kuldeep Singh Sidhu
github : github/singhsidhukuldeep https://github.com/singhsidhukuldeep
웹 사이트 : Kuldeep Singh Sidhu (웹 사이트) http://kuldeepsinghsidhu.com
LinkedIn : Kuldeep Singh Sidhu (LinkedIn) https://www.linkedin.com/in/singhsidhukuldeep/